getOptLambda: Get lambda.min and lambda.1se values

Description Usage Arguments Value

Description

Get lambda.min and lambda.1se values and indices.

Usage

1
getOptLambda(lambda, cvm, cvsd, type.measure)

Arguments

lambda

The values of lambda used in the fits.

cvm

The mean cross-validated error: a vector of length 'length(lambda)'.

cvsd

Estimate of standard error of 'cvm'.

type.measure

Loss function used for CV.

Value

A list with the following elements:

lambda.min

Value of 'lambda' that gives minimum 'cvm'.

lambda.1se

Largest value of 'lambda' such that the error is within 1 standard error of the minimum.

index

A one-column matrix with the indices of 'lambda.min' and 'lambda.1se' in the sequence of coefficients, fits etc.


cvwrapr documentation built on June 11, 2021, 5:21 p.m.