Description Usage Arguments Details Examples
Compute variance explained by a few PCA axis.
1 | pca_var(x, naxe = 10)
|
x |
glPCA object |
naxe |
number of axis for which you want to know explained variance |
PCA from glPca from the package Adegenet
1 2 3 4 5 6 7 | ## simulate a toy dataset
x <- adegenet::glSim(50,4e3, 50, ploidy=2)
## perform PCA
pca1 <- adegenet::glPca(x, nf=3)
## Extract variance
res <- pca_var(pca1, naxe=3)
res
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.