Learn R Programming

LogicForest (version 2.0.0)

predict.LBoost: Prediction of Response Using LBoost

Description

Computes predicted values for newdata for as LBoost model fitted using LBoost.

Usage

## S3 method for class 'LBoost':
predict(object, newdata, \ldots)

Arguments

object
an object of class LBoost.
newdata
a matrix or data frame containing new predictor values. If not given, predictions will be made for the original data used to construct the model.
...
not currently used.

Value

  • If new data are given, predict returns an object of class "LBoost.prediction", that includes a list of elements
  • predictiona numeric vector of predicted responses.
  • weighted.propa numeric vector of the weighted proportion of trees in the forest that predict a class value of one.

See Also

LBoost

Examples

Run this code
data(LF.data, LF.testdata, LBoost.fit)


#NOTE- this is the LBoost model prediction for the original data
predict(object=LBoost.fit)

#predicting classes for new test data
predict(object=LBoost.fit, newdata=LF.testdata[,1:50])

Run the code above in your browser using DataLab