tsmvr_cv: k-fold cross-validation for tsmvr

Description Usage Arguments Value Note

View source: R/tsmvr_cv.R

Description

Calculates the mean and standard deviation of errors over a tsmvr k-fold cross-validation experiment. The error for each base model is the normalized squared error between the true response and the predicted response on a given cross-validation set.

Usage

1
tsmvr_cv(X, Y, s1, s2, pars, quiet = F, seed = NULL)

Arguments

X

design matrix (n-by-p)

Y

response matrix (n-by-q)

s1

regressor matrix sparsity (positive integer)

s2

covariance matrix sparsity (positive integer)

pars

list of algorithm parameters; output of set_parameters

quiet

(logical)

seed

set random seed (integer)

Value

A list of the mean and standard deviation of the errors across the K folds.

Note

See also k_folds, tsmvr, and set_parameters.


spcorum/tsmvr documentation built on Aug. 31, 2019, 8:58 p.m.