Test indices for cross-validation
returns the
test indices idx
= test(c
)idx
for a cvpartition
object c
of type 'holdout'
or 'resubstitution'
.
If c.Type
is 'holdout'
, then
idx
specifies the observations in the test set.
If c.Type
is 'resubstitution'
, then
idx
specifies all observations.
returns the test indices for repetition idx
= test(c
,i
)i
of a cvpartition
object c
of type 'kfold'
or
'leaveout'
.
If c.Type
is 'kfold'
, then
idx
specifies the observations in the i
th
test set or fold.
If c.Type
is 'leaveout'
, then
idx
specifies the observation reserved for testing at
repetition i
.