cv.enspls: Cross Validation for Ensemble Sparse Partial Least Squares...

Description Usage Arguments Value Note Author(s) See Also Examples

Description

K-fold cross validation for ensemble sparse partial least squares regression.

Usage

1
cv.enspls(x, y, nfolds = 5L, verbose = TRUE, ...)

Arguments

x

Predictor matrix.

y

Response vector.

nfolds

Number of cross-validation folds, default is 5. Note that this is the CV folds for the ensemble sparse PLS model, not the individual sparse PLS models. To control the CV folds for single sparse PLS models, please use the argument cvfolds.

verbose

Shall we print out the progress of cross-validation?

...

Arguments to be passed to enspls.fit.

Value

A list containing:

Note

To maximize the probablity that each observation can be selected in the test set (thus the prediction uncertainty can be measured), please try setting a large reptimes.

Author(s)

Nan Xiao <https://nanx.me>

See Also

See enspls.fit for ensemble sparse partial least squares regressions.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
# This example takes one minute to run
## Not run: 
data("logd1k")
x <- logd1k$x
y <- logd1k$y

set.seed(42)
cvfit <- cv.enspls(x, y, reptimes = 10)
print(cvfit)
plot(cvfit)

## End(Not run)

enpls documentation built on May 18, 2019, 9:02 a.m.