View source: R/correlation_filtering_clustering.R
filter_correlated_cell_scExp | R Documentation |
Remove cells that have a correlation score lower than what would be expected by chance with other cells.
filter_correlated_cell_scExp(scExp, random_iter = 5,
corr_threshold = 99, percent_correlation = 1,
downsample = 2500, verbose = TRUE, n_process = 250,
BPPARAM = BiocParallel::bpparam())
scExp |
A SingleCellExperiment object containing 'Cor', a correlation matrix, in reducedDims. |
random_iter |
Number of random matrices to create to calculate random correlation scores. (50) |
corr_threshold |
Quantile of random correlation score above which a cell is considered to be 'correlated' with another cell. (99) |
percent_correlation |
Percentage of the cells that any cell must be 'correlated' to in order to not be filtered. (1) |
downsample |
Number of cells to calculate correlation filtering threshold ? (2500) |
verbose |
Print messages ? (TRUE) |
n_process |
Number of cell to proceed at a time. Increase this number to increase speed at memory cost |
BPPARAM |
BPPARAM object for multiprocessing. See bpparam for more informations. Will take the default BPPARAM set in your R session. |
This functions takes as input a SingleCellExperiment object that must have correlation matrix calculated and outputs a SingleCellExperiment object without lowly correlated cells. TSNE is recalculated.
Returns a SingleCellExperiment object without lowly correlated cells. The calculated correlation score limit threshold is saved in metadata.
data("scExp")
dim(scExp)
scExp_cf = filter_correlated_cell_scExp(scExp,
corr_threshold = 99, percent_correlation = 1)
dim(scExp_cf)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.