#Run the CA using the cca() function (NB: cca() is used for both CA and CCA) spe.ca <- cca(spe) # Identify the significant axes ev<-spe.ca$CA$eig ev[ev>mean(ev)] n=length(ev) barplot(ev, main="Eigenvalues", col="grey", las=2) abline(h=mean(ev), col="red") legend("topright", "Average eigenvalue", lwd=1, col=2, bty="n")