Predicting new observations with previously fitted flexBART model
predict.flexBART.Rd
predict.flexBART
can take the output of flexBART
and probit_flexBART
and use it to make predictions at new inputs.
Usage
# S3 method for class 'flexBART'
predict(object, newdata, ...)
Details
Make predictions at new inputs based on the output of flexBART
.
Useful when the testing dataset is quite large.
If fit
were produced by probit_flexBART
, then the function outputs draws of the fitted probabilities.
Value
When there is only one ensemble, a matrix containing posterior samples of the regression function evaluated at the supplied inputs. For models with multiple ensembles, a list with three elements: (i) a matrix containing posterior samples of the regression function evaluation and (ii) an array containing evaluations of the identified slopes; and (iii) an array containing evaluations of all slopes on the standardized scale.