plotPCAVarPvalue: Plot p-values for the significance of principal components

View source: R/tab_dimensionreduction.R

plotPCAVarPvalueR Documentation

Plot p-values for the significance of principal components

Description

The function plotPCAVarPvalue plots the p-values of significances of principal components. Using the visual output, the optimal number of principal components can be selected.

Usage

plotPCAVarPvalue(var_x, var_perm)

Arguments

var_x

numeric, measured variances

var_perm

matrix, variances obtained by permutation

Details

Internal usage in shinyQC.

Value

gg object from ggplot

Author(s)

Thomas Naake

Examples

x <- matrix(seq_len(100), ncol = 10)
pca <- dimensionReduction(x = x, params = list(center = TRUE, scale = TRUE), 
    type = "PCA")[[2]]
var_x <- explVar(d = pca, type = "PCA")
var_perm <- permuteExplVar(x = x, n = 100, center = TRUE, scale = TRUE)
plotPCAVarPvalue(var_x = var_x, var_perm = var_perm)


tnaake/MatrixQCvis documentation built on Nov. 4, 2024, 7:42 a.m.