I am new to the glmnet
package in R
, and wanted to specify a lambda
function based on the suggestion in a published research paper to the glmnet.cv
function. The documentation suggests that we can supply a decreasing sequence of lambdas
as a parameter. However, in the documentation there are no examples of how to do this.
It would be very grateful if someone can suggest how to go about doing this. Do I pass a vector of 100 odd values (default value for nlambda
) to the function? What restrictions should be there for the min and max value of this vector, if any? Also, are their things to keep in mind regarding nvars
, nobs
etc. while specifying the vector?
Thanks in advance.