createPCA | R Documentation |
Creates a PCA loadings plot using ggplot.
createPCA( df, principal_components = c(1, 2), plots = "scores", cutoff = NULL, features = NULL )
df |
A tidy dataframe with at least sample_id, group, feature and value columns. |
principal_components |
Principal components to be used as x and y axis, default is 1 and 2. |
plots |
Which plots should be made? 'scores', 'loadings' or 'both'. |
cutoff |
Numerical value used to label all features with a loading >cutoff or <-cutoff. Default NULL. |
A PCA loadings plot.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.