knnSmooth | R Documentation |
Smooth bincounts based on k nearest neighbors.
knnSmooth(scCNA, k = 4, BPPARAM = bpparam())
scCNA |
The CopyKit object. |
k |
A numeric with the k nearest neighbor value for smoothing |
BPPARAM |
A BiocParallelParam specifying how the function should be parallelized. |
This function uses a k-nearest neighbors approach to smooth cells
raw bincounts. To do so, the k-nearest neighbors are calculated with
findKNN
. The bincounts of the k-nearest neighbors
for each cell are tallied and an assay called smoothed_bincounts is added to
assay
. After, runVst
and
runSegmentation
. Are re-run by knnSmooth
.
This function results in a trade-off for the elimination of noise at the cost of risk of loss of subclonal structure. To minimize the risk of subclonal structure loss we recommend using the very small values of k.
This function should be followed by applying runVst
and
runSegmentation
to the CopyKit object.
The CopyKit object with an assay smoothed_bincounts
Darlan Conterno Minussi
Runmin Wei
copykit_obj <- mock_bincounts(ncells = 10)
copykit_obj <- runSegmentation(copykit_obj)
copykit_obj <- knnSmooth(copykit_obj)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.