training
Training indices for cross-validation
Description
returns
the training indices idx = training(c)idx for a cvpartition object c of type 'holdout'
or 'resubstitution'.
If
c.Typeis'holdout', thenidxspecifies the observations in the training set.If
c.Typeis'resubstitution', thenidxspecifies all observations.
returns the training indices for the repetitions specified in idx = training(c,i)i of a
cvpartition object c of type 'kfold' or
'leaveout'.
If
c.Typeis'kfold', thenidx(:,j)specifies the observations in training seti(j).If
c.Typeis'leaveout', thenidx(:,j)specifies the observations reserved for training at repetitioni(j).
returns the training indices for all repetitions of a idx = training(c,"all")cvpartition object c. Column j in
idx indicates the observations in training set j
for an object of type 'kfold' or 'leaveout'. (since R2023b)

