How to test the external points in Neural Network

1 visualizzazione (ultimi 30 giorni)
Dear All;
I have built NN model for classification problem but i need to test selected points , i have made the following code to do it but the problem i am facing is that I am getting a consistent results, for example , i select for class 1 , 4 points, class 2 , 3 points .... but when i check the confusion matrix i found different number of points , i do not know if the code below is the right way to do it:
clc; clear; close all; [x1,TXT,RAW]=xlsread('Sh.xlsx','INP'); [t1,TXT2,RAW2]=xlsread('Sh.xlsx','OUT');
x=x1';
t=t1';
size(x) size(t)
net= patternnet (30); % net.divideParam.trainRatio = 70/100; % net.divideParam.valRatio = 15/100; % net.divideParam.testRatio = 15/100; % view(net) net=init(net); [net,tr] = train(net,x,t);
trind=[143 144 264 265 361 362 394 395 431 432 435 436 633 634 664 665 851 852 ]; testX = x(:,trind); testT = t(:,trind);
testY = net(testX); testIndices = vec2ind(testY)
plotconfusion(testT,testY)
  1 Commento
Greg Heath
Greg Heath il 13 Dic 2014
Modificato: Greg Heath il 13 Dic 2014
Insufficient info
What are you classifying?
How many classes? ... Are they mutually exclusive?
Input vector dimensionality?
Number of example in each class?
What are external points?...Nontraining data?

Accedi per commentare.

Risposte (0)

Community Treasure Hunt

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

Start Hunting!

Translated by