Skip to contents

Ridge regression closed form, the grid-search default estimator (hmgrs)

Usage

morie_ridge_estimator(X_train, y_train, alpha = 0)

Arguments

X_train, y_train

Data.

alpha

Ridge penalty (>=0).

Value

function(X_new) -> predictions.

Examples

V <- c(1, 2, 3, 4, 5, 6, 7, 8)
morie_ridge_estimator(V, V)
#> function (X_new) 
#> as.numeric(.morie_gr_mat(X_new, "X_new") %*% th)
#> <environment: 0x5621d016b9e8>