rna_pca_plot: PCA plot of the RNA samples

Description Usage Arguments Examples

View source: R/rna_pca_plot.R

Description

rna_pca_plot function makes a pca plot using the PC1 and PC2 to see how the samples are distributed.

Usage

1
rna_pca_plot(pca_dat, x = 1, y = 2)

Arguments

pca_dat

data frame that is the result after performing pca_prep function

x

PC that should be displayed on the x axis. Default is 1, which is PC1.

y

PC that should be displayed on the y axis. Default is 2, which is PC2.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
pca_data_nb <- pca_prep(norm_dat = sample_vst_dd, "Group")

# To plot PC1 and PC2
ana <- "Sample Title PC1 vs PC2"
caption <- "Data Source: \n Sample Data"

rna_pca_plot(pca_dat = pca_data_nb, x = 1, y = 2)

# To plot PC2 and PC3
rna_pca_plot(pca_dat = pca_data_nb, x = 2, y = 3)

kra277/rnaseqviz documentation built on Feb. 6, 2022, 9:43 p.m.