MATLAB CODE FOR ANN is not producing the desired output,program code is given .

1 view (last 30 days)
inputs = [31 9650.00 3300.00 4350.00]; targets = [11 21 31 51];
hiddenLayerSize = 20; net = fitnet(hiddenLayerSize);
net.divideFcn = 'dividerand'; net.divideMode = 'sample'; net.divideParam.trainRatio = 70/100; net.divideParam.valRatio = 15/100; net.divideParam.testRatio = 15/100;
net.trainFcn = 'trainlm'; net.performFcn = 'mse';
net.plotFcns = {'plotperform','plottrainstate','ploterrhist', ... 'plotregression', 'plotfit'};
[net,tr] = train(net,inputs,targets);
outputs = net(inputs); errors = gsubtract(targets,outputs); performance = perform(net,targets,outputs)
view(net)
sim(net,outputs)

Accepted Answer

Greg Heath
Greg Heath on 16 Oct 2013

More Answers (0)

Community Treasure Hunt

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

Start Hunting!