knn1
代码说明:
K最邻近密度估计技术是一种分类方法,不是聚类方法。 不是最优方法,实践中比较流行。 通俗但不一定易懂的规则是: 1.计算待分类数据和不同类中每一个数据的距离(欧氏或马氏)。 2.选出最小的前K数据个距离,这里用到选择排序法。 3.对比这前K个距离,找出K个数据中包含最多的是那个类的数据,即为待分类数据所在的类。(K nearest neighbor density estimation is a classification method, not a clustering method. It is not the best method, but it is popular in practice. Popular but not necessarily understandable rule is: 1. calculate the distance between the data to be classified and the data in each other (Euclidean or Markov). 2. select the minimum distance from the previous K data, where the choice sorting method is used. 3. compare the previous K distances to find out which K data contains the most data of that class, that is, the class to which the data to be classified is located.)
文件列表:
knn1.m
下载说明:请别用迅雷下载,失败请重下,重下不扣分!