Predicted values based on a boosting tree model object.
# S3 method for BTFit
predict(object, newdata, n.iter, type = "link", single.iter = FALSE, ...)Returns a vector of predictions. By default, the predictions are on the score scale.
If type = "response", then BT converts back to the same scale as the outcome. Note that, a log-link is supposed by construction.
a BTFit object.
data frame of observations for which to make predictions. If missing or not a data frame, if keep.data=TRUE in the initial fit then the original training set will be used.
number of boosting iterations used for the prediction. This parameter can be a vector in which case predictions are returned for each iteration specified.
the scale on which the BT makes the predictions. Can either be "link" or "response". Note that, by construction, a log-link function is used during the fit.
if single.iter=TRUE then predict.BTFit returns the predictions from the single tree n.iter.
not currently used.
Gireg Willame gireg.willame@gmail.com
This package is inspired by the gbm3 package. For more details, see https://github.com/gbm-developers/gbm3/.
predict.BTFit produces a predicted values for each observation in newdata using the first n.iter boosting iterations.
If n.iter is a vector then the result is a matrix with each column corresponding to the BT predictions with n.iter[1] boosting iterations, n.iter[2] boosting
iterations, and so on.
As for the fit, the predictions do not include any offset term. In the Poisson case, please remind that a weighted approach is initially favored.
M. Denuit, D. Hainaut and J. Trufin (2019). Effective Statistical Learning Methods for Actuaries |: GLMs and Extensions, Springer Actuarial.
M. Denuit, D. Hainaut and J. Trufin (2019). Effective Statistical Learning Methods for Actuaries ||: Tree-Based Methods and Extensions, Springer Actuarial.
M. Denuit, D. Hainaut and J. Trufin (2019). Effective Statistical Learning Methods for Actuaries |||: Neural Networks and Extensions, Springer Actuarial.
M. Denuit, D. Hainaut and J. Trufin (2022). Response versus gradient boosting trees, GLMs and neural networks under Tweedie loss and log-link. Accepted for publication in Scandinavian Actuarial Journal.
M. Denuit, J. Huyghe and J. Trufin (2022). Boosting cost-complexity pruned trees on Tweedie responses: The ABT machine for insurance ratemaking. Paper submitted for publication.
M. Denuit, J. Trufin and T. Verdebout (2022). Boosting on the responses with Tweedie loss functions. Paper submitted for publication.
BT, BTFit.