View source: R/predict.ernet.R
predict.ernet | R Documentation |
Similar to other predict methods, this functions predicts fitted values from a fitted ernet object.
## S3 method for class 'ernet' predict(object, newx, s = NULL, type = "response", ...)
object |
fitted |
newx |
matrix of new values for |
s |
value(s) of the penalty parameter |
type |
type of prediction required. Only |
... |
Not used. Other arguments to predict. |
s
is the new vector at which predictions are to be made. If
s
is not in the lambda sequence used for fitting the model, the
predict
function will use linear interpolation to make predictions.
The new values are interpolated using a fraction of predicted values from
both left and right lambda
indices.
The object returned depends on type.
Yuwen Gu and Hui Zou
Maintainer: Yuwen Gu <yuwen.gu@uconn.edu>
ernet
, coef.ernet
,
plot.ernet
, print.ernet
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.