Learn R Programming

Rborist (version 0.1-0)

predict.Rborist: predict method for Rborst

Description

Prediction and test using Rborist.

Usage

## S3 method for class 'Rborist':
predict(object,x,yTest=NULL, quantVec=NULL, ...)

Arguments

object
an object of class Rborist, created from a previous invocation of the command Rborist to train.
x
a design matrix containing new data, with the same signature of predictors as in the training command.
yTest
if specfied, a response vector against which to test the new predictions.
quantVec
a vector of quantiles from which to report new quantile regressions. Only valid if training step specficied quantile regression.
...
not currently used.

Value

  • A list with the following components:

    If regression, either a vector yPred containing the predictions for each row, if yTest is null, or the mean-square error, mse of the predictions computed with respect to expected yTest.

    If categorical, either a vector of predictions yPred for null yTest or a confusion matrix, confusion, computed with repsect to expected yTest.

    If training included quantile regression, the matrix quantiles records the vector of predicted quantiles for each row.

See Also

Rborist