plot_prcomp | R Documentation |
Plot PCA of subsampled data using ggplot
plot_prcomp(
df_samples,
protein_names,
color_var = "treatment",
subsample_size = 10000,
repel = TRUE
)
df_samples |
Data frame or tibble with proteins counts, cell condition, and group information |
protein_names |
A vector of column names of protein to use in the analysis |
color_var |
A column name |
subsample_size |
Subsample per color_var variable |
repel |
Repel labels |
cowplot
object
set.seed(23)
df <- generate_data()
protein_names <- names(df)[3:12]
df <- dplyr::mutate_at(df, protein_names, function(x) asinh(x/5))
CytoGLMM::plot_prcomp(df,
protein_names = protein_names,
color_var = "condition")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.