ParameterGrid: Tuning Parameters Grid

Description Usage Arguments Value See Also Examples

View source: R/grid.R

Description

Defines a tuning grid from a set of parameters.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
ParameterGrid(...)

## S3 method for class 'param'
ParameterGrid(..., size = 3, random = FALSE)

## S3 method for class 'list'
ParameterGrid(x, size = 3, random = FALSE, ...)

## S3 method for class 'parameters'
ParameterGrid(x, size = 3, random = FALSE, ...)

Arguments

...

named param objects as defined in the dials package.

size

single integer or vector of integers whose positions or names match the given parameters and which specify the number of values used to construct the grid.

random

number of unique points to sample at random from the grid defined by size, or FALSE for all points.

x

list of named param objects or a parameters object.

Value

ParameterGrid class object that inherits from parameters and Grid.

See Also

TunedModel

Examples

1
2
3
4
5
6
7
## GBMModel tuning parameters
grid <- ParameterGrid(
  n.trees = dials::trees(),
  interaction.depth = dials::tree_depth(),
  random = 5
)
TunedModel(GBMModel, grid = grid)

MachineShop documentation built on June 18, 2021, 9:06 a.m.