how to implement knn classification?

1 次查看(过去 30 天)
we are working on a power system on which we have to determine whether the failure of the power system is a fault or not a fault. We have created a dataset with all possibilities of faults and not faults of the system called training set. we have created another excel sheet called the training set in which we have taken some values of faults and not faults from the dataset. We want to use knn algorithm and euclidean distance to compare/classify whether the readings in the training set are the values of faults or not faults when compared with the original dataset. As we are putting four five values in the training set, how do we make matlab read and classify all the values one after the other without manually entering the values
P.S- 1 represents 'fault' and 2 represents 'not a fault'
  1 个评论
Image Analyst
Image Analyst 2017-3-30
If you can't figure out how to adapt the examples in the help for knn then make it easy for people to help you by attaching your reference data set and "unknown" data set.

请先登录,再进行评论。

回答(0 个)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by