# Does matlab neural network toolbox use early-stopping by default?

I have trained a neural network in matlab using the toolbox (code below), but I no longer have a maltab license; does anyone know if the validation in this toolbox by default is only to assess the performance of the neural network, or if it is used for early-stopping (when the error starts enhancing instead of diminishing, stop training)?

I think I remember seeing something related to this when training the ANN (number of epochs after which the training was stopped by the validation), but like I said I no longer have matlab and I can't find anything about it online... Thanks in advance!


% Create a Pattern Recognition Network
hiddenLayerSize = 15;
net = patternnet(hiddenLayerSize, trainFcn);

% Choose Input and Output Pre/Post-Processing Functions
% For a list of all processing functions type: help nnprocess
net.input.processFcns = {'removeconstantrows','mapminmax'};

% Setup Division of Data for Training, Validation, Testing
% For a list of all data division functions type: help nndivision
net.divideFcn = 'dividerand';  % Divide data randomly
net.divideMode = 'sample';  % Divide up every sample
net.divideParam.trainRatio = 65/100;
net.divideParam.valRatio = 20/100;
net.divideParam.testRatio = 15/100;

% Choose a Performance Function
% For a list of all performance functions type: help nnperformance
net.performFcn = 'crossentropy';  % Cross-Entropy

% Choose Plot Functions
% For a list of all plot functions type: help nnplot
net.plotFcns = {'plotperform','plottrainstate','ploterrhist', ...
'plotconfusion', 'plotroc'};

% Train the Network
[net,tr] = train(net,x,t);$$$$
`