pbFlatten: pbFlatten Flatten pseudobulk SCE

Description Usage Arguments Value Examples

View source: R/pbFlatten.R

Description

Flattens a pseudobulk SingleCellExperiment as returned by aggregateData such that all cell subpopulations are represented as a single assay.

Usage

1
pbFlatten(pb, normalize = TRUE)

Arguments

pb

a pseudobulk SingleCellExperiment as returned by aggregateData, with different subpopulations as assays.

normalize

logical specifying whether to compute a logcpm assay.

Value

a SingleCellExperiment.

Examples

1
2
3
4
5
data(sce)
library(SingleCellExperiment)
pb_stack <- aggregateData(sce)
(pb_flat <- pbFlatten(pb_stack))
ncol(pb_flat) == ncol(pb_stack)*length(assays(pb_stack))

muscat documentation built on Nov. 8, 2020, 7:47 p.m.