Learn R Programming

ecodist (version 1.2.9)

vf: Vector fitting

Description

Fits environmental variables to an ordination configuration.

Usage

vf(ord, vars, nperm = 100)

Arguments

ord

matrix containing a 2-dimensional ordination result with axes as columns.

vars

matrix with ancillary variables as columns.

nperm

number of permutation for the significance test. If nperm = 0, the test will be omitted.

Value

an object of class vf containing matrix with the first 2 columns containing the scores for every variable in each of the 2 dimensions of the ordination space. r is the maximum correlation of the variable with the ordination space, and pval is the result of the permutation test.

Details

Vector fitting finds the maximum correlation of the individual variables with a configuration of samples in ordination space.

References

Jongman, R.H.G., C.J.F. ter Braak and O.F.R. van Tongeren. 1995. Data analysis in community and landscape ecology. Cambridge University Press, New York.

See Also

plot.vf

Examples

Run this code
# NOT RUN {
# }
# NOT RUN {
# Example of multivariate analysis using built-in iris dataset
data(iris)
iris <- iris[seq(1, 150, by=3),]
iris.md <- distance(iris[,1:4], "mahal")

# Minimum-stress 2-dimensional nonmetric multidimensional scaling configuration
# Uses small number of separate ordinations (5) to increase speed of example.
# Use more for final analysis.
iris.nmds <- nmds(iris.md, mindim=2, maxdim=2, nits=3)
iris.nmin <- nmds.min(iris.nmds)

# Plot NMDS result with symbols denoting species
plot(iris.nmin, pch=as.numeric(iris[,5]))

# Fit vectors for the main variables to the NMDS configuration
iris.vf <- vf(iris.nmin, iris[,1:4], nperm=10)
plot(iris.vf, col="blue")
# }
# NOT RUN {
# }

Run the code above in your browser using DataLab