chmAddPCA: Add PCA coordinates to an NG-CHM.

chmAddPCAR Documentation

Add PCA coordinates to an NG-CHM.

Description

Add PCA coordinates as hidden covariate bars to an axis of an NG-CHM. One hidden covariate bar is added for each PCA coordinate (up to ndim coordinates). Coordinates are given names 'BASENAME.coordinate.N', where BASENAME is specified by the parameter basename (default "PC") and N ranges from 1 to the number of added covariate bars.

Usage

chmAddPCA(hm, axis, prc, basename = "PC", ndim = 2)

Arguments

hm

The NGCHM to add the coordinates to.

axis

The NGCHM axis ("row" or "column") to add the coordinates to.

prc

Principal component coordinates (output of stats::prcomp()) for the specified NGCHM axis.

ndim

The maximum number of coordinates to add.

baseName

The prefix to use for the coordinate names.

Value

The NGCHM with added coordinates.

See Also

chmAddTSNE()

chmAddUMAP()

chmAddUWOT()

chmAddReducedDim()

Examples

prc <- prcomp(TCGA.GBM.EXPR);
hm <- chmNew ("gbm", TCGA.GBM.EXPR);
hm <- chmAddPCA(hm, "column", prc);


bmbroom/NGCHMR documentation built on April 18, 2022, 6:52 p.m.