CellDEEP.Kmean.RdPools cells into "pseudocells" by applying k-means clustering to PCA embeddings. This reduces data sparsity while maintaining the biological grouping of sample, cluster, and condition.
CellDEEP.Kmean(
dataset,
n_cells = 10,
nstart = 100,
assay_name = "RNA",
readcounts = "mean",
min_cells_per_subgroup = 25
)A Seurat object. Must have PCA reductions calculated.
Integer. Target number of cells to pool into each pseudocell.
Integer. Number of random sets to start with in kmeans.
Character. The assay to pull counts from (default "RNA").
Character. Aggregation method: "mean" (rounded average), "sum", "10X" (mean * 10).
Integer. Minimum cells required in each sample-cluster subgroup to perform pooling (default 25).
A new Seurat object where each "cell" is a pooled group of original cells.
This function requires that PCA has already been run on the input dataset,
as it uses the "pca" reduction for clustering.
# pooled_obj <- CellDEEP.Kmean(dataset = my_seurat, n_cells = 10, readcounts = "mean")