Perform Clustering on a SingleCellExperiment object
Source:R/split_cluster_test.R
perform_clustering.Rd
Perform Clustering on a SingleCellExperiment object
Usage
perform_clustering(
sce,
ret_obj = FALSE,
normalized_method = "LogNormalize",
use.kmeans = FALSE,
kmeans.nstart = 1,
resolution = 0.5,
step = 0.05,
maxiter = 40,
louvain.nstart = 1,
louvain.alg = 1,
seed.cluster = 0,
kmeans.whiten = FALSE,
pca.whiten = FALSE,
npcs = 10,
k.param = 20,
test.use = "t",
test.from.raw = FALSE,
signal_measurement = "tstat",
verbose = FALSE
)
Arguments
- sce
A SingleCellExperiment object
- ret_obj
(Default:
FALSE
) whether to return thesce
after operation instead of returning the signal measurement- normalized_method
Normalization method. Possible choices:
LogNormalize
,sct
, ornone
- use.kmeans
if
TRUE
, then clustering using kmeans with two clusters, otherwise, useSeurat::FindClusters
and need to findresolution
to achieve two clusters- kmeans.nstart
the
nstart
parameter forkmeans
- resolution
the
resolution
parameter forSeurat::FindClusters
- step
To find a resolution with desired number of clusters, the step size for changing the
resolution
parameter- maxiter
maximum iteration for searching
resolution
to have two clusters- louvain.nstart
the
n.start
parameter forSeurat::FindClusters
- louvain.alg
the
algorithm
parameter forSeurat::FindClusters
- seed.cluster
the
random.seed
parameter forSeurat::FindClusters
- kmeans.whiten
whether to whitening for the kmeans clustering
- pca.whiten
whether to whitening for PCA if using Louvain algorithms
- npcs
number of PCs, the parameter
npcs
used inSeurat::RunPCA
- k.param
the parameter
k.param
used inSeurat::FindNeighbors
- test.use
The hypothesis testing for DE test. Possible choices:
t
,wilcox
,poisson
, andnegbinom
- test.from.raw
whether to perform the testing on the original data without normalization or on the normalized data
- signal_measurement
the signal measurement. Possible choices: the test statistic
tstat
, or the signed p-valuepval
- verbose
whether to print internal log messages