Dear list,
I am trying to use a PCA to predict new dataset, I know how to get the
variance explained for the original PCA, but how could I get the
percent of variance explained by each axis for this new PCA ordination?
Thanks a lot.
x1 <- matrix(rnorm(30), 6, 5)
x2 <- matrix (rnorm(40), 8, 5)
pca1<-prcomp(x1, retx=TRUE)
pca1$sdev
pred <- predict(pca1, x2)
Feng Liu
______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.