View source: R/ComputeSilhouetteScores.R
ComputeSilhouetteScores | R Documentation |
This function will compute the silhouette score for each cluster identified by Seurat
's Louvain modularity optimization community detection algorithm.
ComputeSilhouetteScores(seurat.obj = NULL, dist.metric = "cosine", avg = TRUE)
seurat.obj |
The input object for which silhouette score will be computed. Defaults to NULL. |
dist.metric |
Which distance metric should be used? Defaults to "cosine", but any of the metrics used by |
avg |
Should the average scores for each cluster be returned, or should a dataframe of every observation's cluster identity and score be returned? Defaults to TRUE. |
If avg = TRUE
, returns the average silhouette score per cluster, else returns a cell-level dataframe of the cluster identities & silhouette scores.
Jack Leary
CosineDist
.
## Not run:
ComputeSilhouetteScores(seurat.obj)
ComputeSilhouetteScores(seurat.obj,
dist.metric = "euclidean",
avg = FALSE)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.