lars_predict: LARS Prediction

View source: R/lars_predict.R

predict.mlpack_larsR Documentation

LARS Prediction

Description

An implementation of Least Angle Regression (stagewise/lasso), also known as LARS. This program can use a pre-trained LARS/LASSO/Elastic Net model to output regression predictions from a test set.

Usage

## S3 method for class 'mlpack_lars'
predict(object, newdata, ...)

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

Arguments

object

An instantiated model object for which prediction is desired

newdata

A test data set

...

Additional optional arguments affecting the prediction

input_model

Trained LARS model to use (LARS).

test

Matrix containing points to regress on (test points) (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).

Value

A list with several components defining the class attributes:

predictions

Matrix containing predicted responses (numeric matrix).

Author(s)

mlpack developers

Examples

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

mlpack documentation built on July 23, 2026, 1:08 a.m.

Related to lars_predict in mlpack...