visGroup: visGroup

Description Usage Arguments Details Value See Also Examples

View source: R/VisCms.R

Description

Plot group label in a reduced dimensional plot.

Usage

1
visGroup(sce, group, dim_red = "TSNE")

Arguments

sce

A SingleCellExperiment object.

group

Character. Name of group/batch variable. Needs to be one of names(colData(sce)).

dim_red

Character. Name of embeddings to use as subspace for plotting. Default is "TSNE".

Details

Plots a reduced dimension plot colored by group parameter. The dimesion reduction embedding can be specified, but only tsne embeddings will automatically be computed by runTSNE. Embeddings from data integration methods (e.g. mnn.correct) can be used as long as they are specified in reducedDimNames(sce).

Value

a ggplot object.

See Also

visOverview, visMetric

Other visualize functions: visCluster()

Examples

1
2
3
4
5
library(SingleCellExperiment)
sim_list <- readRDS(system.file("extdata/sim50.rds", package = "CellMixS"))
sce <- sim_list[[1]][, c(1:50, 300:350)]

visGroup(sce, "batch")

almutlue/CellMixS documentation built on Dec. 22, 2020, 11:07 a.m.