how to use k means
3 次查看(过去 30 天)
显示 更早的评论
I have detected features of image using
I = imread('cameraman.tif');
points = detectSURFFeatures(I);
now i have to apply k means to cluster the points,plz ell how i can use k means
1 个评论
回答(1 个)
Wayne King
2013-5-16
Jose-Luis has a very good suggestion.
You can use kmeans() as follows:
I = imread('cameraman.tif');
points = detectSURFFeatures(I);
% I'll assume 3 clusters
idx = kmeans(points.Location,3);
另请参阅
类别
在 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!