A wrapper function for doubletCells. Identify potential doublet cells based on simulations of putative doublet expression profiles. Generate a doublet score for each cell.
runDoubletCells( inSCE, sample = NULL, useAssay = "counts", nNeighbors = 50, simDoublets = max(10000, ncol(inSCE)), seed = 12345, size.factors.norm = NULL, size.factors.content = NULL, subset.row = NULL, block = 10000, d = 50, force.match = FALSE, force.k = 20, force.ndist = 3, BNPARAM = BiocNeighbors::KmknnParam(), BSPARAM = BiocSingular::bsparam(), BPPARAM = BiocParallel::SerialParam() )
| inSCE | A SingleCellExperiment object. |
|---|---|
| sample | Character vector. Indicates which sample each cell belongs to. doubletCells will be run on cells from each sample separately. |
| useAssay | A string specifying which assay in the SCE to use. |
| nNeighbors | Number of nearest neighbors used to calculate density for doublet detection. Default 50. |
| simDoublets | Number of simulated doublets created for doublet detection. Default 10000. |
| seed | Seed for the random number generator. Default 12345. |
| size.factors.norm | A numeric vector of size factors for normalization
of |
| size.factors.content | A numeric vector of size factors for RNA content
normalization of |
| subset.row | See |
| block | An integer scalar controlling the rate of doublet generation, to keep memory usage low. |
| d | An integer scalar specifying the number of components to retain after the PCA. |
| force.match | A logical scalar indicating whether remapping of simulated doublets to original cells should be performed. |
| force.k | An integer scalar specifying the number of neighbours to use for
remapping if |
| force.ndist | A numeric scalar specifying the bandwidth for remapping
if |
| BNPARAM | A |
| BSPARAM | A |
| BPPARAM | A |
A SingleCellExperiment object with the 'scran_doubletCells_score' column added to the colData slot.
This function is a wrapper function for doubletCells.
runDoubletCells runs doubletCells for each
sample within inSCE iteratively. The
resulting doublet scores for all cells will be appended to the
colData of inSCE.
Lun ATL (2018). Detecting doublet cells with scran. https://ltla.github.io/SingleCellThoughts/software/doublet_detection/bycell.html
data(scExample, package = "singleCellTK") sce <- sce[, colData(sce)$type != 'EmptyDroplet'] sce <- runDoubletCells(sce)#>