Take the 2-minute tour ×
Cross Validated is a question and answer site for people interested in statistics, machine learning, data analysis, data mining, and data visualization. It's 100% free, no registration required.

This is similar to question Caret re-sampling methods, although that really never answered this part of the question in an agreed upon way.

caret's train function offers cv and repeatedcv. What is the difference in say doing:

MyTrainControl=trainControl(
    method = "cv",
    number=5,
    repeats=5
)

vs

MyTrainControl=trainControl(
   method = "repeatedcv",
   number=5,
   repeats=5
)

I understand cv breaks the set into k-folds (parameter number), and then starts over and runs it parameters repeats number of times.

The only thing I could think of is that maybe regular cv with repeats uses the same exact indexes for the folds each time? essentially running the cv on the same exact folds each time, vs perhaps repeatedcv selects new folds each times?

Can someone clarify?

share|improve this question

1 Answer 1

According to the caret manual, page 22, the parameter repeats only applies when the method is set to repeatedcv, so no repetition is performed when the method is set to cv. So the difference between both methods is indeed that repeatedcv repeats and cv does not.


Aside: Repeating a crossvalidation with exactly the same splitting will yield exactly the same result for every repetition (assuming that the model is trained in a deterministic manner), which is not only inefficient, but also dangerous when it comes to comparing the validation results for different model algorithms in a statistical manner. So be aware of this if you ever have to program a validation yourself.

share|improve this answer
    
Steffen, thank you for your answer. –  Brian Feeny Nov 28 '12 at 18:25
    
@BrianFeeny glad to help. If the answer was satisfactory, please consider to click the check mark below the vote up / down button. See the FAQ on asking questions for details :) –  steffen Nov 29 '12 at 6:40

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.