Neural Network Pattern Recognition target data values 0 to 4

1 Ansicht (letzte 30 Tage)
Panagiotis Makris
Panagiotis Makris am 30 Dez. 2020
Hello,
I want to train a neural network with data that is about heart diseases. The problem is on my target data, they can accept values (0,1,2,3 and 4).
What i have is a double array that contains values like (0,2,1,0,1,2,4,4,2,3,1,0,2,0,1,3,4 etc...). It's size is 1 x 297 and the range is 0 to 4.
What i tried is to convert those values to binary values with de2bi(targets) function so they are represented like this example:
1) 0 0 1
2) 0 1 0 --> (These are the first 3 examples from the array that i showed to you before)
3) 0 0 0
^ ^ ^
0 2 1
But the problem is that when i am trying to show the plot confusion diagram it shows only 3 classes as results because as you can see in my example my binary data are represented in a 3 row that starts with the value 1. So this is clearly wrong.
So my question is how can i convert my data in a way that they will show right as result in the plot confusion diagram?
Thank you very much guys

Antworten (0)

Produkte


Version

R2018a

Community Treasure Hunt

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

Start Hunting!

Translated by