This function calculates the explained variance of a given principal component in a PCA.
An integer: what principal component?
A numeric, the proportion of variance in the dataset explained by the principal component.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.