Artificial Neural Network code for this dataset?
3 views (last 30 days)
Show older comments
Debalina Pal
on 31 May 2018
Commented: Debalina Pal
on 1 Jun 2018
can anyone send me the code for ANN which is applicable in this dataset?
0 Comments
Accepted Answer
Majid Farzaneh
on 31 May 2018
Hi, you can use something like this:
I=xlsread('forneuralnetworkdataset.xls');
inputs=I(:,1:3)';
targets=I(:,4)';
net=feedforwardnet(10);
net=train(net,inputs,targets);
3 Comments
Majid Farzaneh
on 1 Jun 2018
You're welcome. You have the trained net. Simply use the net as a function:
out=net([28;89;993])
or
test_data=I(1:10,1:3)';
outs=net(test_data);
Note that the output of a default feed-forward network is not integer. You can use round, ceil, floor or fix function to round the output.
out=round(net([28;89;993]))
More Answers (0)
See Also
Categories
Find more on Deep Learning Toolbox in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!