visMetric: visMetric

Description Usage Arguments Details Value See Also Examples

View source: R/VisCms.R

Description

Plot metric scores in a reduced dimensional plot.

Usage

1
visMetric(sce_cms, metric_var = "cms", dim_red = "TSNE", log10_val = FALSE)

Arguments

sce_cms

A SingleCellExperiment object with the result scores (e.g. cms) to plot within colData(res_object).

metric_var

Character Name of the metric scores to use. Default is "cms".

dim_red

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

log10_val

Logical. Indicating if -log10(metric) should be plotted.

Details

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

Value

a ggplot object.

See Also

visOverview, visGroup

Other visualize metric functions: visHist(), visOverview()

Examples

1
2
3
4
5
6
library(SingleCellExperiment)
sim_list <- readRDS(system.file("extdata/sim50.rds", package = "CellMixS"))
sce <- sim_list[[1]][, c(1:30, 300:320)]
sce_cms <- cms(sce, "batch", k = 20, n_dim = 2)

visMetric(sce_cms)

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