applyCutoffs | R Documentation |
Applies separation and mahalanobies distance cutoffs.
applyCutoffs(x, assay = "exprs", mhl_cutoff = 30, sep_cutoffs = NULL)
x |
a |
assay |
character string specifying which assay data to use.
Should be one of |
mhl_cutoff |
numeric mahalanobis distance threshold above which events
should be unassigned; ignored if |
sep_cutoffs |
non-negative numeric of length one or of same length
as the number of rows in the |
the input SingleCellExperiment
x
is returned with
updated colData
columns "bc_id"
and "mhl_dist"
,
and an additional int_metadata
slot "mhl_cutoff"
containing the applied mahalanobies distance cutoff.
Helena L Crowell helena.crowell@uzh.ch
Zunder, E.R. et al. (2015). Palladium-based mass tag cell barcoding with a doublet-filtering scheme and single-cell deconvolution algorithm. Nature Protocols 10, 316-333.
library(SingleCellExperiment)
# construct SCE
data(sample_ff, sample_key)
sce <- prepData(sample_ff)
# assign preliminary barcode IDs
# & estimate separation cutoffs
sce <- assignPrelim(sce, sample_key)
sce <- estCutoffs(sce)
# use estimated population-specific
# vs. global separation cutoff(s)
sce1 <- applyCutoffs(sce)
sce2 <- applyCutoffs(sce, sep_cutoffs = 0.35)
# compare yields after applying cutoff(s)
c(global = mean(sce1$bc_id != 0),
specific = mean(sce2$bc_id != 0))
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.