optimal hidden nodes number
2 views (last 30 days)
Show older comments
coqui on 11 Jan 2015
Commented: coqui on 9 May 2015
I want to determine the optimal number of hidden nodes using narnet in order to predict the next'day index, i have just a question:
I found two proposition about Hmax:
1) Hmax= Hub
2) Hmax=floor(Hub/10)% for example, but I have not understand how we can determine the number "10"
What is the difference between these two propositions and what's the right one.
Greg Heath on 13 Jan 2015
Neither is always the right one. There are many ways to choose a value that works. I typically start searching with ~10 values in a range 1<= Hmin <= H <= Hmax <= Hub by trial and error. The upper bound Hub is chosen so that the number of training equations, Ntrneq, is not less than the number of unknown weights Nw. For robust designs it is desired that Hmax << Hub. That is where the empirical factor of 10 comes from. For each value in the range I usually design Ntrials = 10 candidates for a total of 100 designs. On rare occasions I have used Ntrials = 15 or 20.
I have explained this logic so many times it is ridiculous for me to say any more than search the NEWSGROUP and/or ANSWERS using any subset of the above variables. Usually
greg Hub Ntrials
If there is not enough data to provide enough equations so that Ntrneq >> Nw, it is wise to use or combine an alternate approach like validation-set-stopping and/or regularization. I tend to use valstop. For the latter search on
There is recent evidence (Sorry, I lost the reference) that, for difficult designs, combining valstop and regularization can be very effective.
Hope this helps.
Thank you for formally accepting my answer
More Answers (0)
Find more on Function Approximation and Clustering 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!