Prediction for SVM, Decision Tree and Naive Bayers

1 view (last 30 days)
Hi, my knowledge to matlab is very limited. However i had done a coding for my model to test the all the 3 classifiers prediction but all my prediction is 100% even when i decrease from 3 features to 2 features. May i know why is this so, i seriously need some help in these segment for my project. l have attached the codings and l hope someone is able to help me. Thanks in advance and cheers!

Answers (1)

Harsha Priya Daggubati
Harsha Priya Daggubati on 13 May 2020
Hi,
It is fine to obtain 100% accuracy, if your data is a linear. If not, one possible reason would be similarity between your traning and testing data. You can try increasing your dataset, by adding random noise and check the accuracy of your classifier.
Just to make sure your classifier is fine, and the trouble is with the data you can use the datasets shipped to you with your MATLAB.
You could look at few datasets available in the following links:
You can also split the data into training, validation and test sets to tune your classifier once enough data is gathered.

Community Treasure Hunt

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

Start Hunting!