| clu_tune | R Documentation |
Tune clustering hyperparameters by evaluating an intrinsic metric over a parameter grid and selecting the elbow (max curvature).
clu_tune(base_model, folds = 10, ranges = NULL)
base_model |
base model for tuning |
folds |
number of folds for cross-validation |
ranges |
a list of hyperparameter ranges to explore |
returns a clu_tune object.
Satopaa, V. et al. (2011). Finding a “Kneedle” in a Haystack.
data(iris)
# fit model
model <- clu_tune(cluster_kmeans(k = 0), ranges = list(k = 1:10))
model <- fit(model, iris[,1:4])
model$k
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.