plot.cv.sparseSVM {sparseSVM} | R Documentation |
Plot the cross-validation curve for a "cv.sparseSVM" object
Description
Plot the cross-validation curve for a "cv.sparseSVM" object against the
lambda
values used, along with standard error bars.
Usage
## S3 method for class 'cv.sparseSVM'
plot(x, log.l = TRUE, nvars = TRUE, ...)
Arguments
x |
A |
log.l |
Should |
nvars |
If |
... |
Other graphical parameters to |
Details
Produces a plot of mean cv errors at each lambda
along with upper and lower standard error bars.
Author(s)
Congrui Yi and Yaohui Zeng
Maintainer: Congrui Yi <eric.ycr@gmail.com>
See Also
Examples
X = matrix(rnorm(1000*100), 1000, 100)
b = 3
w = 5*rnorm(10)
eps = rnorm(1000)
y = sign(b + drop(X[,1:10] %*% w + eps))
cv.fit <- cv.sparseSVM(X, y, ncores = 2, seed = 1234)
plot(cv.fit)
plot(cv.fit, log.l = FALSE)
[Package sparseSVM version 1.1-6 Index]