plot.cv.cpernet: Plot the cross-validated curve produced by cv.cpernet

Description Usage Arguments Details Author(s) See Also Examples

View source: R/plot.cv.cpernet.R

Description

Plots the cross-validated curve, and upper and lower standard deviation curves, as a function of the lambda values used. This function is modified based on the plot.cv.glmnet function from the glmnet package.

Usage

1
2
## S3 method for class 'cv.cpernet'
plot(x, sign.lambda = 1, ...)

Arguments

x

fitted cv.cpernet object

sign.lambda

either plot against log(lambda) (default) or its negative if sign.lambda=-1.

...

other graphical parameters to plot

Details

A plot is produced.

Author(s)

Yuwen Gu and Hui Zou
Maintainer: Yuwen Gu <guxxx192@umn.edu>

See Also

cv.cpernet

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
set.seed(1)
n <- 100
p <- 400
x <- matrix(rnorm(n*p), n, p)
y <- rnorm(n)
tau <- 0.30
pf <- abs(rnorm(p))
pf2 <- abs(rnorm(p))
w <- 2.0
lambda2 <- 1
m2.cv <- cv.cpernet(y = y, x = x, w = w, tau = tau, eps = 1e-8, 
              pf.mean = pf, pf.scale = pf2,
              standardize = FALSE, lambda2 = lambda2)
plot(m2.cv)

SALES documentation built on May 2, 2019, 5:08 a.m.

Related to plot.cv.cpernet in SALES...