Closed
Description
Right now, if a modeling function using glmnet
gets a specific penalty
value, the model cannot make predictions on any other values. If no value is given, the model can predict on anything but there is no default value to be used with predict()
.
I propose doing what caret
does:
- if a penalty value is given, save it but do not pass that value to the
lambda
argument toglmnet
. - attach the supplied penalty value to the the
glmnet
fit object. - when using
predict()
, use the value attached to theglmnet
object.
It is suboptimal to modify the underlying object but that would enable use to have the best of both worlds; predict()
works as expected (and without error) and multi_predict()
can also be used.
Metadata
Metadata
Assignees
Labels
No labels