Learn R Programming

mlpack (version 4.8.0)

predict.mlpack_linear_regression: Linear Regression Prediction

Description

Predictions from model.

Usage

# S3 method for mlpack_linear_regression
predict(object, newdata, ...)

linear_regression_predict( input_model, test, verbose = getOption("mlpack.verbose", FALSE) )

Value

A list with several components defining the class attributes:

output_predictions

Matrix containing predicted responses (numeric row).

Arguments

object

An instantiated model object for which prediction is desired

newdata

A test data set

...

Additional optional arguments affecting the prediction

input_model

Existing LinearRegression model to use (LinearRegression).

test

Matrix containing X' (test regressors) (numeric matrix).

verbose

Display informational messages and the full list of parameters and timers at the end of execution. Default value "getOption("mlpack.verbose", FALSE)" (logical).

Author

mlpack developers

Examples

Run this code
# \dontrun{ pred <- predict(model, newdata=X_test) }

Run the code above in your browser using DataLab