Cross Validation following the dataset

Asked

Viewed 139 times

1

Regarding cross validation, I would like to know if when we use the command below the system makes a random choice of data or sequential. I am looking for a way to use the data order to generate the Folds (K=10) and not a random form.

cross_validation = trainControl (method="cv", number=10) 

classificador = naiveBayes(x=base[-13], y=base$target, trcontrol=cross_validation)

1 answer

1


The choice of the data is random. If the argument method is not defined, the method of resampling used is the bootstrap. By definition, bootstrap is a random (i.e., non-sequential) method of resampling with replenishment.

Also, the expression "Cross Validation in the dataset sequence" makes no sense. Cross-validation is a resampling technique and should be done randomly. If it is not random, it is not cross-validation.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.