View source: R/unsupervised-validation.R
| tidy_silhouette_analysis | R Documentation |
Silhouette Analysis Across Multiple k Values
tidy_silhouette_analysis(
data,
max_k = 10,
method = "kmeans",
nstart = 25,
dist_method = "euclidean",
linkage_method = "average"
)
data |
A data frame or tibble |
max_k |
Maximum number of clusters to test (default: 10) |
method |
Clustering method: "kmeans" (default) or "hclust" |
nstart |
If kmeans, number of random starts (default: 25) |
dist_method |
Distance metric (default: "euclidean") |
linkage_method |
If hclust, linkage method (default: "average") |
A tibble with k and average silhouette widths
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.