backTransPCA | R Documentation |
This function back-transforms principal component scores to their original values.
backTransPCA(pca, x = NULL)
pca |
Object of class |
x |
Either |
Numeric vector.
x <- data.frame(
x1 = 1:20 + rnorm(20),
x2 = 1:20 + rnorm(20, 0, 5),
x3 = sample(20, 20)
)
pca1 <- prcomp(x, center=FALSE, scale=FALSE)
pca2 <- prcomp(x, center=TRUE, scale=FALSE)
pca3 <- prcomp(x, center=TRUE, scale=TRUE)
backTransPCA(pca1)
backTransPCA(pca2)
backTransPCA(pca3)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.