Learn R Programming

ncvreg (version 3.4-0)

summary.cv.ncvreg: Summarizing inferences based on cross-validation

Description

Summary method for cv.ncvreg objects

Usage

## S3 method for class 'cv.ncvreg':
summary(object, ...)
## S3 method for class 'summary.cv.ncvreg':
print(x, digits, ...)

Arguments

object
A "cv.ncvreg" object.
x
A "summary.cv.ncvreg" object.
digits
Number of digits past the decimal point to print out. Can be a vector specifying different display digits for each of the five non-integer printed values.
...
Further arguments passed to or from other methods.

Value

  • summary.cv.ncvreg produces an object with S3 class "summary.cv.ncvreg". The class has its own print method and contains the following list elements:
  • penaltyThe penalty used by ncvreg.
  • modelEither "linear" or "logistic", depending on the family option in ncvreg.
  • nNumber of observations
  • pNumber of regression coefficients (not including the intercept).
  • minThe index of lambda with the smallest cross-validation error.
  • lambdaThe sequence of lambda values used by cv.ncvreg.
  • cveCross-validation error (deviance).
  • r.squaredProportion of variance explained by the model, as estimated by cross-validation.
  • snrSignal to noise ratio, as estimated by cross-validation.
  • sigmaFor linear regression models, the scale parameter estimate.
  • peFor logistic regression models, the prediction error (misclassification error).

References

Breheny, P. and Huang, J. (2011) Coordinate descent algorithms for nonconvex penalized regression, with applications to biological feature selection. Ann. Appl. Statist., 5: 232-253.

See Also

ncvreg, cv.ncvreg, plot.cv.ncvreg

Examples

Run this code
## Linear regression
data(prostate)
X <- as.matrix(prostate[,1:8])
y <- prostate$lpsa
cvfit <- cv.ncvreg(X, y)
summary(cvfit)

## Logistic regression
data(heart)
X <- as.matrix(heart[,1:9])
y <- heart$chd
cvfit <- cv.ncvreg(X, y, family="binomial")
summary(cvfit)

Run the code above in your browser using DataLab