Description: In this program, the training sample set containing 30 samples, the vector length sample the {1,18,11,11,0.5513196} K = 5, K-nearest neighbor classifier. Samples read from the file data.txt The program runs The results showed that all the samples, as well as its class, be classified sample category ({1,18,11,11,0.5513196} belong to the " 2" category), as well as its five nearest neighbor category and it distance.
To Search:
File list (Check if you may need any files):
K-最近邻分类\data.txt
............\knn\classify.cpp
............\...\classify.dsp
............\...\classify.dsw
............\...\classify.ncb
............\...\classify.opt
............\...\classify.plg
............\...\Debug\classify.exe
............\...\.....\classify.ilk
............\...\.....\classify.obj
............\...\.....\classify.pch
............\...\.....\classify.pdb
............\...\.....\vc60.idb
............\...\.....\vc60.pdb
............\...\Myknn.dsp
............\...\Myknn.dsw
............\...\Myknn.ncb
............\...\Myknn.opt
............\...\Myknn.plg
............\...\Output.dat
............\KNN程序的说明.txt
............\输出结果.txt
............\knn\Debug
............\knn
K-最近邻分类