summary.gbm: Summary of a gbm object
Description
Computes the relative influence of each variable in the gbm object.Usage
summary.gbm(object,
cBars=length(object$var.names),
n.trees=object$n.trees,
plotit=TRUE,
order=TRUE,
method=relative.influence,
...)
Arguments
object
a gbm
object created from an initial call to
gbm
. cBars
the number of bars to plot. If order=TRUE
the only the
variables with the cBars
largest relative influence will appear in the
barplot. If order=FALSE
then the first cBars
variables will
appear in th
n.trees
the number of trees used to generate the plot. Only the first
n.trees
trees will be used.
plotit
an indicator as to whether the plot is generated.
order
an indicator as to whether the plotted and/or returned relative
influences are sorted.
method
The function used to compute the relative influence.
relative.influence
is the default and is the same as that
described in Friedman (2001). The other current (and experimental) choice is
...
other arguments passed to the plot function.
Value
- Returns a data frame where the first component is the variable name and the
second is the computed relative influence, normalized to sum to 100.
Details
For distribution="gaussian"
this returns exactly a set of
Type III sum of squares for each variable normalized to sum to 100. For other
loss functions this returns the reduction attributeable to each varaible in sum
of squared error in predicting the gradient on each iteration. It describes the
relative influence of each variable in reducing the loss function. See the
references below for exact details on the computation.References
J.H. Friedman (2001). "Greedy Function Approximation: A Gradient Boosting
Machine," Annals of Statistics 29(5):1189-1232.
L. Breiman (2001). "Random Forests," Available at ftp://ftp.stat.berkeley.edu/pub/users/breiman/randomforest2001.pdf.