中文说明: KNN 算法其实简单的说就是“物以类聚”,也就是将新的没有被分类的点分类为周围的点中大多数属于的类。它采用测量不同特征值之间的距离方法进行分类,思想很简单:如果一个样本的特征空间中最为临近(欧式距离进行判断)的K个点大都属于某一个类,那么该样本就属于这个类。这就是物以类聚的思想。
English Description:
&In fact, KNN algorithm simply means "birds of a feather flock together", that is to say, it classifies new unclassified points into most of the surrounding points. It uses the method of measuring the distance between different eigenvalues for classification, and the idea is very simple: if most of the k points in the feature space of a sample (judged by Euclidean distance) belong to a certain class, then the sample belongs to this class. This is the idea that birds of a feather flock together.