makeResampleDesc | R Documentation |
A description of a resampling algorithm contains all necessary information to create a ResampleInstance, when given the size of the data set.
makeResampleDesc(
method,
predict = "test",
...,
stratify = FALSE,
stratify.cols = NULL,
fixed = FALSE,
blocking.cv = FALSE
)
method |
( |
predict |
( |
... |
(any)
|
stratify |
( |
stratify.cols |
(character) |
fixed |
( |
blocking.cv |
( |
Some notes on some special strategies:
Use “RepCV”. Then you have to set the aggregation function for your preferred performance measure to “testgroup.mean” via setAggregation.
Use “Bootstrap” for bootstrap and set predict to “both”. Then you have to set the aggregation function for your preferred performance measure to “b632” via setAggregation.
Use “Bootstrap” for bootstrap and set predict to “both”. Then you have to set the aggregation function for your preferred performance measure to “b632plus” via setAggregation.
Use makeFixedHoldoutInstance.
Object slots:
character(1)
)Name of resampling strategy.
integer(1)
)Number of iterations. Note that this is always the complete number of generated train/test sets, so for a 10-times repeated 5fold cross-validation it would be 50.
character(1)
)See argument.
logical(1)
)See argument.
See arguments.
(ResampleDesc).
For common resampling strategies you can save some typing by using the following description objects:
holdout a.k.a. test sample estimation (two-thirds training set, one-third testing set)
2-fold cross-validation
3-fold cross-validation
5-fold cross-validation
10-fold cross-validation
Other resample:
ResamplePrediction
,
ResampleResult
,
addRRMeasure()
,
getRRPredictionList()
,
getRRPredictions()
,
getRRTaskDesc()
,
getRRTaskDescription()
,
makeResampleInstance()
,
resample()
# Bootstraping
makeResampleDesc("Bootstrap", iters = 10)
makeResampleDesc("Bootstrap", iters = 10, predict = "both")
# Subsampling
makeResampleDesc("Subsample", iters = 10, split = 3 / 4)
makeResampleDesc("Subsample", iters = 10)
# Holdout a.k.a. test sample estimation
makeResampleDesc("Holdout")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.