predict.RandomForest: 'predict.RandomForest'

View source: R/variables.R

predict.RandomForestR Documentation

predict.RandomForest

Description

Predicts values for numeric outcomes and group membership for categories based on newdata and a fitted RandomForest object. A value (which may be NA) is returned for every instance including those with missing data and for the fitted data before filtering in the case that newdata is not specified. NA is returned for cases with unfitted factor levels.

Usage

## S3 method for class 'RandomForest'
predict(object, newdata = NULL, na.action = na.pass, ...)

Arguments

object

A RandomForest object.

newdata

Optionally, a data frame including the variables used to fit the model. If omitted, the data supplied to RandomForest() is used before any filtering.

na.action

Function determining what should be done with missing values in newdata. The default is to predict NA.

...

Additional arguments to pass to predict


NumbersInternational/flipMultivariates documentation built on Feb. 26, 2024, 5:38 a.m.