cvf {plmmr}R Documentation

Cross-validation internal function for cv_plmm

Description

Internal function for cv_plmm which calls plmm on a fold subset of the original data.

Usage

cvf(i, fold, type, cv_args, ...)

Arguments

i

Fold number to be excluded from fit.

fold

n-length vector of fold-assignments.

type

A character argument indicating what should be returned from predict.plmm. If type == 'lp' predictions are based on the linear predictor, $X beta$. If type == 'individual' predictions are based on the linear predictor plus the estimated random effect (BLUP).

cv_args

List of additional arguments to be passed to plmm.

...

Optional arguments to predict_within_cv

Value

a list with three elements:


[Package plmmr version 4.2.1 Index]