can you please explain the logic of this code???

5 views (last 30 days)
net1 = newff(minmax(T),[60 50 1],{'logsig','logsig','purelin'},'trainrp');
net1.trainParam.show = 6000;
net1.trainParam.lr = 0.20;
net1.trainParam.epochs = 13000;
net1.trainParam.goal = 3e-10;

Answers (1)

Jayanti
Jayanti on 9 Jul 2025
Hi Priyanka,
The provided MATLAB code is use to create a feedforward neural network. First line creates a 3-layer feedforward neural network using the "newff" function with 60 and 50 neurons in first and second hidden layer with "logsig" activation function followed by 1 neuron in output layer with "purelin" activation. "minmax(T)" specifies the input range based on the minimum and maximum values of the input data "T".
The following code lines sets the training progress, learning rate, epochs and goals of the network.
Also note that the function "newff" has been obselete. You can refer to the below MATLAB Answers thread for more information:

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!