How to find optimal k from k means clustering by using elbow method

31 次查看(过去 30 天)
I want to find optimal k from k means clustering by using elbow method . I have 100 customers and each customer contain 8689 data sets. How can I create a program to cluster this data set into appropriate k groups.

采纳的回答

kira
kira 2019-5-2
old question, but I just found a way myself looking at matlab documentation:
klist=2:n;%the number of clusters you want to try
myfunc = @(X,K)(kmeans(X, K));
eva = evalclusters(net.IW{1},myfunc,'CalinskiHarabasz','klist',klist)
classes=kmeans(net.IW{1},eva.OptimalK);

更多回答(1 个)

Saranya  A
Saranya A 2018-3-8
编辑:KSSV 2021-2-11
This function will help you to find the optimum number of clusters. https://in.mathworks.com/matlabcentral/fileexchange/49489-best-kmeans-x-

类别

Help CenterFile Exchange 中查找有关 Direct Search 的更多信息

标签

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by