View source: R/sperrorest_misc.R
| as.represampling | R Documentation |
Functions for handling represampling objects, i.e. lists of
resampling objects.
as.represampling(object, ...) ## S3 method for class 'list' as.represampling(object, ...) ## S3 method for class 'represampling' print(x, ...) is_represampling(object)
object |
object of class |
... |
currently not used. |
x |
object of class |
represampling objects are (names) lists of resampling objects.
Such objects are typically created by partition_cv, partition_kmeans,
represampling_disc_bootstrap and related functions.
In r-repeated k-fold cross-validation, for example, the corresponding
represampling object has length r, and each of its r resampling
objects has length k.
as.resampling_list coerces object to class represampling while
coercing its elements to resampling objects. Some validity checks are
performed.
as.represampling methods return an object of class represampling
with the contents of object.
resampling, partition_cv, partition_kmeans, represampling_disc_bootstrap, etc.
# Muenchow et al. (2012), see ?ecuador # Partitioning by elevation classes in 200 m steps: fac <- factor(as.character(floor(ecuador$dem / 300))) summary(fac) parti <- as.resampling(fac) # a list of lists specifying sets of training and test sets, # using each factor at a time as the test set: str(parti) summary(parti)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.