cv_plots: Plots of Cross-validation results

Description Usage Arguments Value Author(s) Examples

View source: R/mainFunctions.R

Description

Slightly misnamed as user could choose BIC as a criteria for "cv.rq.pen" object. Function is able to discern between the two types of evaluation criteria and provides appropriate labels for the plot.

Usage

1
cv_plots(model,logLambda=TRUE,loi=NULL,...)

Arguments

model

"cv.rq.pen" object.

logLambda

Plot of lambdas is on the log scale.

loi

Index of lambdas to be plotted. Default is all of the lambdas from "cv.rq.pen" object.

...

Additional items to be sent to plot function.

Value

Plot of how cross validation statistic changes with lambda.

Author(s)

Ben Sherwood

Examples

1
2
3
4
x <- matrix(rnorm(800),nrow=100)
y <- 1 + x[,1] - 3*x[,5] + rnorm(100)
lassoModels <- cv.rq.pen(x,y)
cv_plot <- cv_plots(lassoModels)

rqPen documentation built on May 30, 2017, 2:02 a.m.

Search within the rqPen package
Search all R packages, documentation and source code