k-means 聚类过程演示

k-means是一种非监督 (从下图 0 当中我们可以看到训练数据并没有标签标注类别)的聚类算法:

K-Means clustering intends to partition n objects into k clusters in which each object belongs to the cluster with the nearest mean. This method produces exactly k different clusters of greatest possible distinction. The best number of clusters k leading to the greatest separation (distance) is not known as a priori and must be computed from the data. The objective of K-Means clustering is to minimize total intra-cluster variance, or, the squared error function: 

 

0.initial

 

1.select centroids randomly   

  

 

2.assign points

 

 3.update centroids

 4.reassign points

 5.update centroids

 

 6.reassign points

 

7.iteration

 

reference:

https://www.naftaliharris.com/blog/visualizing-k-means-clustering/

https://www.saedsayad.com/clustering_kmeans.htm

转载请注明来源:https://www.cnblogs.com/lnas01/p/10347650.html

 

转载于:https://www.cnblogs.com/lnas01/p/10347650.html

  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值