Learn R Programming

wsrf (version 1.5.14)

predict.wsrf: Predict Method for wsrf Model

Description

Give the predictions for the new data by the forest model built from wsrf.

Usage

## S3 method for class 'wsrf':
predict(object, newdata, type=c("response",
  "class", "prob", "vote", "aprob", "waprob"), ...)

Arguments

object
object of class wsrf.
newdata
the data that needs to be predicted. Its format should be the same as that for wsrf.
type
the type of prediction required, indicating the type of output, and can be one of the values below: [object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
...
Optional additional arguments. At present no additional arguments are used.

Value

  • a vector of length nrow(newdata) if given type of response or class, otherwise, a matrix of nrow(newdata) * (number of class label).

See Also

wsrf