How to interpret Neural Network output if it is NaN?
2 visualizzazioni (ultimi 30 giorni)
Mostra commenti meno recenti
Code to classify output into 3 classes- 0,1 and 2 (indicating no fault, line fault and irradiance fault). Output shows NaN and -0.00
Code:
% code
filename= 'new_3classes_Modif_NEURAL_NET_INPUT.xlsx';
S= xlsread (filename, 'B3:B106');
T= xlsread (filename, 'C3:C106');
V= xlsread (filename, 'D3:D106');
I= xlsread (filename, 'E3:E106');
P= xlsread (filename, 'G3:F106');
O= xlsread (filename, 'H3:G106');
C = [S T V I P];
x= transpose (C);
t = O.';
net = cascadeforwardnet(10);
net = configure(net,x,t);
y1 = net(x);
net = train(net,x,t);
y2 = net(x);
plotconfusion (t,y2);
end
0 Commenti
Risposte (1)
Greg Heath
il 23 Apr 2017
For classification into mutually exclusive classes, the target columns should be [0,1] unit vectors. For examples, search the NEWSGROUP and ANSWERS using:
greg patternnet
and
greg patternnet tutorial
Hope this helps.
Thank you for formally accepting my answer
Greg
0 Commenti
Vedere anche
Categorie
Scopri di più su Modeling and Prediction with NARX and Time-Delay Networks in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!