Two of the most important uses for Neural Networks are regression(function approximation, curvefitting) and classification/pattern-recognition.
The best way to design NNs is via the Neural Network Toolbox
In general, the best function to use for regression is FITNET. Start with the help and doc documentation using the command line commands
Next check out some of my posts on the NEWSGROUP and ANSWERS. Search using
In general, the best function to use for classification/pattern-recognition is PATTERNNET. Start with the help and doc documentation using the command line commands
help patternnet
doc patternnet
Next check out some of my posts on the NEWSGROUP and ANSWERS. Search using
Finally, use MATLAB data to practice with
help nndatasets
doc nndatasets
If you have problems, it is easier for us to help if you use those datasets.
The help and doc examples use as many default settings as possible. Therefore my best advice for beginners is to begin your designs similarly with one exception. Since by default, the trn/val/tst data division and initial weights are chosen randomly, it is important to know the initial state of the random number generator. The best way to do that is for you to set it to your favorite state before using TRAIN. If designing multiple designs in a loop, initialize RNG before the loop.
The default topology is I-H-O ( H=10 default) for I dimensional input vectors and corresponding O-dimensional Output target vectors. The one hidden layer contains H=10 hidden nodes containing tansig (tanh) transfer functions.
The one hidden layer net is a universal approximator. Increasing the number of hidden nodes increases the ability to model more complex functions. However using more than needed decreases the ability to operate well on unseen data. The only reason to use more layers is if you want to decrease the total number of hidden nodes or, to try to model subclasses for classification.
Replaces the 10 tansig hidden units with 200. Typically, this is a ridiculous number.
net.divideParam.trainRatio=70/100
net.divideParam.valRatio=15/100
net.divideParam.testRatio=15/100
Divides the data into training, validation and test subsets with the ratio 70/15/15. However, this is the default ratio. Therefore those statements can be deleted.
Hope this helps.
Thank you for formally accepting my answer
Greg
Best Answer