divideblock
(To be removed) Divide targets into three sets using blocks of indices
divideblock will be removed in a future release. For more information,
see Transition Legacy Neural Network Code to dlnetwork Workflows.
For advice on updating your code, see Version History.
Syntax
[trainInd,valInd,testInd] = divideblock(Q,trainRatio,valRatio,testRatio)
Description
[trainInd,valInd,testInd] = divideblock(Q,trainRatio,valRatio,testRatio)
separates targets into three sets: training, validation, and testing. It takes the
following inputs:
Q | Number of targets to divide up. |
trainRatio | Ratio of targets for training. Default =
|
valRatio | Ratio of targets for validation. Default =
|
testRatio | Ratio of targets for testing. Default =
|
and returns
trainInd | Training indices |
valInd | Validation indices |
testInd | Test indices |
Examples
[trainInd,valInd,testInd] = divideblock(3000,0.6,0.2,0.2);
Network Use
Here are the network properties that define which data division function to use, what
its parameters are, and what aspects of targets are divided up, when
train is called.
net.divideFcn net.divideParam net.divideMode
Version History
Introduced in R2008aSee Also
Time Series
Modeler | fitrnet (Statistics and Machine Learning Toolbox) | fitcnet (Statistics and Machine Learning Toolbox) | trainnet | trainingOptions | dlnetwork