Help in k means clustering
1 回表示 (過去 30 日間)
古いコメントを表示
Dear all, I am still not comfortable with k-means clustering in classification. Especially while rerunning with the code
eva = evalclusters(params,'kmeans','silhouette','KList',[2:20]);
It gives me different cases. Also while using separate code like
[idx,cent,sumdist, meansilh] =kcluster('param2W_sac.cld', optkn, s);
there is different answers. I think I am concemptually wrong in using rng-function. Is there some one to help me in this manner. It will be great is there availability to have online tutor in such cases.
0 件のコメント
採用された回答
the cyclist
2014 年 9 月 30 日
There is a randomness component in k-means clustering, as you surmise.
Have you tried putting the statement
rng(1)
at the beginning of your code? This will set the generator seed, and therefore produce the same series of pseudorandom numbers each time you run it.
0 件のコメント
その他の回答 (1 件)
参考
カテゴリ
Help Center および File Exchange で Cluster Analysis and Anomaly Detection についてさらに検索
製品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!