cv.sail
plot.cv.sail.Rd
Plots the cross-validation curve, and upper and lower standard
deviation curves, as a function of the lambda
values used.
# S3 method for cv.sail plot(x, sign.lambda = 1, ...)
x | fitted |
---|---|
sign.lambda | Either plot against |
... | Other graphical parameters to plot |
A plot is produced and nothing is returned
This is a port of plot.cv.glmnet
Jerome Friedman, Trevor Hastie, Robert Tibshirani (2010). Regularization Paths for Generalized Linear Models via Coordinate Descent. Journal of Statistical Software, 33(1), 1-22. http://www.jstatsoft.org/v33/i01/.
if (FALSE) { if(interactive()){ data("sailsim") f.basis <- function(i) splines::bs(i, degree = 3) cvfit <- cv.sail(x = sailsim$x[,1:10,drop=F], y = sailsim$y, e = sailsim$e, basis = f.basis, nfolds = 10) plot(cvfit) } }