trimCounts: Trim Counts

Description Usage Arguments Value Examples

View source: R/trimCounts.R

Description

Trims an input count matrix such that each value greater than a threshold value and each value less than a provided lower threshold value is trimmed to the lower treshold value.

Usage

1
trimCounts(counts, trimValue = c(10, -10))

Arguments

counts

matrix

trimValue

where trimValue[1] for upper threshold and trimValue[2] as lower threshold (default is c(10,-10))

Value

trimmed counts matrix

Examples

1
2
data(sce_chcl, package = "scds")
assay(sce_chcl, "countsTrimmed") <- trimCounts(assay(sce_chcl, "counts"), c(10, -10))

singleCellTK documentation built on Nov. 8, 2020, 5:21 p.m.