tuner

0th

Percentile

Tuning Wrapper Function

Convenience function to train a method using different tuning parameters.

Keywords
resampling, similarity
Usage
tuner(method, tunerange, …)
Arguments
method

a character string. Name of the R function to train the method.

tunerange

a list. A list that specifies the range of values to be used for each tuning parameter. Each element of the list should be a vector that specifies the values to be tested for the tuning parameter. The element must be named after the corresponding tuning parameter of the method (see examples).

additional information passed to method (such as formula, data, subset, etc.).

Details

This function can be used to train any method using different values for its tuning parameter(s). The result can be passed directly to stability to compare the stability of results based on different values of the tuning parameter.

Value

A list that contains all fitted model objects.

Additional information about the range of values used for the tuning parameters is attached to the resulting object as an attribute.

See Also

stability

Aliases
  • tuner
Examples
# NOT RUN {
# }
# NOT RUN {
library("partykit")

## tuning cforest using different values of its tuning parameter mtry
r <- tuner("cforest", tunerange = list(mtry = 1:4), formula = Species ~ ., data = iris)
stability(r, control = stab_control(seed = 1234))

## receive information about the range of tuning parameters
attr(r, "range")

# }
# NOT RUN {
# }
Documentation reproduced from package stablelearner, version 0.1-2, License: GPL-2 | GPL-3

Community examples

Looks like there are no examples yet.