plot_PCA {CB2} | R Documentation |
A function to plot the first two principal components of samples.
Description
This function will perform a principal component analysis, and it returns a ggplot object of the PCA plot.
Usage
plot_PCA(sgcount, df_design)
Arguments
sgcount |
The input matrix contains read counts of sgRNAs for each sample. |
df_design |
The table contains a study design. |
Value
A ggplot2 object contains a PCA plot for the input.
library(CB2) data(Evers_CRISPRn_RT112) plot_PCA(Evers_CRISPRn_RT112$count, Evers_CRISPRn_RT112$design)
[Package CB2 version 1.3.4 Index]