vboot.elnet: Internal bootstraping validation linear glmnet model

Description Usage Arguments

View source: R/parallel_vboot.R

Description

Validate glmnet linear regression using bootstrap.

Usage

1
2
3
4
## S3 method for class 'elnet'
vboot(fit, x, y, s, nfolds = 5, B = 200,
  cv_replicates = 100, lambda = TRUE, n_cores = max(1,
  parallel::detectCores() - 1))

Arguments

fit

Object from glmnet fit.

x

A matrix of the predictors, each row is an observation vector.

y

A vector of response variable. Should be numeric.

s

Value of the penalty parameter "lambda" selected from the original 'cv.glmnet'.

nfolds

Number of folds for cross validation as in 'cv.glmnet'.

B

Number of bootsrap samples.

cv_replicates

Number of replicates for the cross-validation step.

lambda

By default, the validation is adjusted using 'lambda.1se' which has error within 1 standard error of the best model. If 'FALSE' the 'lambda.min' referered to the lowest CV error will be used.

n_cores

number of cores to use in parallel. Default detectCores()-1.


BootValidation documentation built on Aug. 14, 2018, 5:03 p.m.