Fit Hierarchical Clustering to klassets_cluster object using stats::hclust
Source: R/clusters.R
fit_hclust.RdFit Hierarchical Clustering to klassets_cluster object using stats::hclust
Arguments
- df
A
klassets_clusterobject.- k
A numeric determine number of clusters. This value is passed to
stats::cutreemethod.- method
The agglomeration method to be used.
Examples
set.seed(12)
df <- sim_groups(n = 200, groups = 3)
plot(df)
dfhc <- fit_hclust(df, k = 4)
plot(dfhc)