How to vary the units in the hidden layer for a feedforwardnet and get the number of units which give the highest % of Correct Classification?
조회 수: 1 (최근 30일)
이전 댓글 표시
The code looks as follows, n is the number of layers in the input layer. I want to vary the value of n from 1 to 100 and obtain the value for which the value of Correct Classification i.e. 100*(1-c) is maximum:
NW = feedforwardnet(n);
view(NW);
[NW,tr] = train(NW, Train_Feat, Train_Resp);
nntraintool;
plotperform(tr);
testR = NW(Test_Feat);
plotconfusion(Test_Resp,testR);
[c,cm] = confusion(Test_Resp,testR);
fprintf('Percentage Correct Classification : %f%%\n', 100*(1-c));
fprintf('Percentage Incorrect Classification : %f%%\n', 100*c);
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Deep Learning Toolbox에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!