forked from tidymodels/parsnip
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathboost_tree.Rd
85 lines (71 loc) · 2.8 KB
/
boost_tree.Rd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/boost_tree.R
\name{boost_tree}
\alias{boost_tree}
\title{Boosted trees}
\usage{
boost_tree(
mode = "unknown",
engine = "xgboost",
mtry = NULL,
trees = NULL,
min_n = NULL,
tree_depth = NULL,
learn_rate = NULL,
loss_reduction = NULL,
sample_size = NULL,
stop_iter = NULL
)
}
\arguments{
\item{mode}{A single character string for the prediction outcome mode.
Possible values for this model are "unknown", "regression", or
"classification".}
\item{engine}{A single character string specifying what computational engine
to use for fitting.}
\item{mtry}{A number for the number (or proportion) of predictors that will
be randomly sampled at each split when creating the tree models
(specific engines only)}
\item{trees}{An integer for the number of trees contained in
the ensemble.}
\item{min_n}{An integer for the minimum number of data points
in a node that is required for the node to be split further.}
\item{tree_depth}{An integer for the maximum depth of the tree (i.e. number
of splits) (specific engines only).}
\item{learn_rate}{A number for the rate at which the boosting algorithm adapts
from iteration-to-iteration (specific engines only).}
\item{loss_reduction}{A number for the reduction in the loss function required
to split further (specific engines only).}
\item{sample_size}{A number for the number (or proportion) of data that is
exposed to the fitting routine. For \code{xgboost}, the sampling is done at
each iteration while \code{C5.0} samples once during training.}
\item{stop_iter}{The number of iterations without improvement before
stopping (specific engines only).}
}
\description{
\code{boost_tree()} defines a model that creates a series of decision trees
forming an ensemble. Each tree depends on the results of previous trees.
All trees in the ensemble are combined to produce a final prediction.
There are different ways to fit this model. The method of estimation is
chosen by setting the model \emph{engine}.
\Sexpr[stage=render,results=rd]{parsnip:::make_engine_list("boost_tree")}
More information on how \pkg{parsnip} is used for modeling is at
\url{https://www.tidymodels.org/}.
}
\details{
This function only defines what \emph{type} of model is being fit. Once an engine
is specified, the \emph{method} to fit the model is also defined.
The model is not trained or fit until the \code{\link[=fit.model_spec]{fit.model_spec()}} function is used
with the data.
}
\examples{
show_engines("boost_tree")
boost_tree(mode = "classification", trees = 20)
}
\references{
\url{https://www.tidymodels.org}, \href{https://www.tmwr.org/}{\emph{Tidy Models with R}}
}
\seealso{
\Sexpr[stage=render,results=rd]{parsnip:::make_seealso_list("boost_tree")},
\code{\link[=xgb_train]{xgb_train()}}, \code{\link[=C5.0_train]{C5.0_train()}}
}