% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/expand.R
\name{expand_model}
\alias{expand_model}
\title{Model Expansion Over Tuning Parameters}
\usage{
expand_model(object, ..., random = FALSE)
}
\arguments{
\item{object}{\link[=models]{model} function, function name, or object; or
another object that can be \link[=as.MLModel]{coerced} to a model.}

\item{...}{named vectors or factors or a list of these containing the
parameter values over which to expand \code{object}.}

\item{random}{number of points to be randomly sampled from the parameter grid
or \code{FALSE} if all points are to be returned.}
}
\value{
\code{list} of expanded models.
}
\description{
Expand a model over all combinations of a grid of tuning parameters.
}
\examples{
\donttest{
## Requires prior installation of suggested package gbm to run

data(Boston, package = "MASS")

models <- expand_model(GBMModel, n.trees = c(50, 100),
                                 interaction.depth = 1:2)

fit(medv ~ ., data = Boston, model = SelectedModel(models))
}

}
\seealso{
\code{\link{SelectedModel}}
}
