plot.cv.grpnet: Plot Cross-Validation Curve for cv.grpnet Fits

View source: R/cv.grpnet.R

plot.cv.grpnetR Documentation

Plot Cross-Validation Curve for cv.grpnet Fits

Description

Plots the mean cross-validation error, along with lower and upper standard deviation curves, as a function of log(lambda).

Usage

## S3 method for class 'cv.grpnet'
plot(x, sign.lambda = 1, nzero = TRUE, ...)

Arguments

x

Object of class "cv.grpnet"

sign.lambda

Default plots log(lambda) on the x-axis. Set to -1 to plot -1*log(lambda) on the x-axis instead.

nzero

Should the number of non-zero groups be printed on the top of the x-axis?

...

Additional arguments passed to the plot function.

Details

Produces cross-validation plot only (i.e., nothing is returned).

Value

No return value (produces a plot)

Note

Syntax and functionality were modeled after the plot.cv.glmnet function in the glmnet package (Friedman, Hastie, & Tibshirani, 2010).

Author(s)

Nathaniel E. Helwig <helwig@umn.edu>

References

Friedman, J., Hastie, T., & Tibshirani, R. (2010). Regularization paths for generalized linear models via coordinate descent. Journal of Statistical Software, 33(1), 1-22. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.18637/jss.v033.i01")}

Helwig, N. E. (2024). Versatile descent algorithms for group regularization and variable selection in generalized linear models. Journal of Computational and Graphical Statistics. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1080/10618600.2024.2362232")}

See Also

cv.grpnet for k-fold cross-validation of lambda

plot.grpnet for plotting the regularization path

Examples

# see 'cv.grpnet' for plotting examples
?cv.grpnet

grpnet documentation built on Oct. 12, 2024, 1:07 a.m.