add.spec.scores {BiodiversityR}R Documentation

Add Species Scores to Unconstrained Ordination Results


Calculates scores (coordinates) to plot species for PCoA or NMS results that do not naturally provide species scores. The function can also rescale PCA results to use the choice of rescaling used in vegan for the rda function (after calculating PCA results via PCoA with the euclidean distance first).


add.spec.scores(ordi, comm, method="cor.scores", multi=1, Rscale=F, scaling="1")



Ordination result as calculated by cmdscale, isoMDS, sammon, postMDS, metaMDS or NMSrandom.


Community data frame with sites as rows, species as columns and species abundance as cell values.


Method for calculating species scores. Method "cor.scores" calculates the scores by the correlation between site scores and species vectors (via function cor), method "wa.scores" calculates the weighted average scores (via function wascores) and method "pcoa.scores" calculates the scores by weighing the correlation between site scores and species vectors by variance explained by the ordination axes.


Multiplier for the species scores.


Use the same scaling method used by vegan for rda.


Scaling method as used by rda.


The function returns a new ordination result with new information on species scores. For PCoA results, the function calculates eigenvalues (not sums-of-squares as provided in results from function cmdscale), the percentage of explained variance per axis and the sum of all eigenvalues. PCA results (obtained by PCoA obtained by function cmdscale with the Euclidean distance) can be scaled as in function rda, or be left at the original scale.


Roeland Kindt


Kindt, R. & Coe, R. (2005) Tree diversity analysis: A manual and software for common statistical methods for ecological and biodiversity studies.


distmatrix <- vegdist(dune, method="euc")
# Principal coordinates analysis with 19 axes to estimate total variance
Ordination.model1 <- cmdscale (distmatrix, k=19, eig=TRUE, add=FALSE)
# Change scores for second axis
Ordination.model1$points[,2] <- -1.0 * Ordination.model1$points[,2]
Ordination.model1 <- add.spec.scores(Ordination.model1, dune, 
    method='pcoa.scores', Rscale=TRUE, scaling=1, multi=1)
# Compare Ordination.model1 with PCA
Ordination.model2 <- rda(dune, scale=FALSE)
ordiplot(Ordination.model1, type="text")
abline(h = 0, lty = 3)
abline(v = 0, lty = 3)
plot(Ordination.model2, type="text", scaling=1)

[Package BiodiversityR version 2.16-1 Index]