Classification accuracy change every time

2 次查看(过去 30 天)
Dear
I extracted feature from emg signal and when i classify it by below methods:
1-classification app: During classifcation classifier and accuracy change every time. like when i classify first time it show fine SVM give 70% accuracy and next time when I classify it then it show highest accuracy at 60% by KNN.
2- Secondly, I used nnstart app, it also show different accuracy of same data at different times.
Kindlly explain me its reason.
Thank you

回答(1 个)

Walter Roberson
Walter Roberson 2019-12-5
Classification app and the functions reached from nnstart all initialize randomly. If you need to be able to reproduce every time, then you would need to use rng() to set the same random number seed each time.
  3 个评论
Walter Roberson
Walter Roberson 2019-12-5
You would type
rng(655321)
at the command line before starting the classification app. Then do one classification step. Then quit classification app and do the same rng() again and start classification app again before running the test again.
You just might be able to get away with typing the rng() command at the command line between runs in the GUI of classification app.
Generally speaking, if you need to exactly replicate runs to prove that you can exactly replicate runs, then you should probably not be using the classification app or nnstart, and should instead be using the underlying MATLAB library calls with the datastructures initialized as appropriate for your situation.
It is normal that if you fit exactly the same data twice in a row in classification app or nnstart, that you will get different results. It is designed that way.
This is inherent to how the classification tools work. The tools are not able to calculate a global "best" set of parameters: they randomize starting conditions and they calculate with those conditions, and then they randomize again and calculate again, and keep doing that for a while, looking for the best set of starting conditions.
Ali Asghar
Ali Asghar 2019-12-5
Thank you for this explanation.
Can tell me more about "Underlying MATLAB library call" so I make the appropirate result that which feature and classification is good for which emg signals.

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 Sequence and Numeric Feature Data Workflows 的更多信息

标签

产品

Community Treasure Hunt

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

Start Hunting!

Translated by