Description Usage Arguments Details Examples
View source: R/lipidome_comparison_pca.R
'scree_factoextra' takes a prcomp element and diplays the percentage of variance explained by the principal components in a barplot.
1 | scree_factoextra(prcomp_element, title = "Scree plot", out_path = "none")
|
prcomp_element |
object of class prcomp or pca. Produced by base::prcomp or FactoMineR::PCA. |
title |
string. Main title of plot. Default: "Scree plot" |
out_path |
string. Path to save plot to png. If out_path is empty, the plot is printed to the device. |
This function takes a prcom element (i.e. an element generated by the base::prcomp function), and displays the percentage of variance explained by each principal component in a barplot. Additionally there is also a dot- and line graph.
1 2 | {pca_iris <- prcomp(dplyr::select_if(iris, is.numeric))
scree_factoextra(pca_iris, title = "Scree plot iris")}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.