MATLAB Answers

How could I optimize structure of ANN using GA?

1 view (last 30 days)
saman abdanan
saman abdanan on 9 Oct 2015
I have written matlab code as follows:
inputs = X(:,:)'; five neurons for input targets = y(:,:)'; one neuron for output
net=newff(minmax(inputs),targets, (Number of Neurons in Hidden Layer),{'tansig','purelin'},'trainlm');
[net,tr]=train(net,inputs,targets); and ........
I want to find the number of neurons in the hidden layers. I have always used trail an errors method to find the must appropriate numbers of neurons. I wonder if any one could help me to find this number using GA.
Cheers Saman

Answers (0)

Community Treasure Hunt

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

Start Hunting!