October 2017
Beginner to intermediate
572 pages
26h 1m
English
Perform the following steps to perform the k-fold cross-validation with the caret package:
> control = trainControl(method="repeatedcv", number=10, repeats=3)
> model = train(churn~., data=trainset, method="rpart", preProcess="scale", trControl=control)
> model Ouput CART 2315 samples 16 predictor 2 classes: 'yes', 'no' Pre-processing: scaled Resampling: Cross-Validated (10 fold, repeated 3 times) Summary of sample sizes: 2084, 2083, 2082, 2084, 2083, 2084, ... Resampling results ...
Read now
Unlock full access