Learn R Programming

interep (version 0.1.0)

cv.interep: This function does k-fold cross-validation for interep and returns the optimal value of lambda.

Description

This function does k-fold cross-validation for interep and returns the optimal value of lambda.

Usage

cv.interep(e, z, y, response = "continuous", initiation = NULL,
  alpha.i = 1, lambda1, lambda2, nfolds, maxits = 30, corre)

Arguments

e

matrix of environment factors.

z

matrix of omics factors. In the case study, the omics measurements are lipidomics data.

y

the longitudinal response.

response

type of the longitudinal response, the default is continuous.

initiation

the method for iniating the coefficient vector. The default is lasso.

alpha.i

the elastic-net mixing parameter. The program adopts the elastic-net to choose initial values of the coefficient vector. alpha.i is the elastic-net mixing parameter, with 0 \(\le\) alpha.i \(\le\) 1. alpha.i=1 is the lasso penalty, and alpha.i=0 is the ridge penalty. The default is 1. If the user chooses a method other than elastic-net to initialize coefficients, alpha.i will be ignored.

lambda1

a user-supplied sequence of \(\lambda_{1}\) values, which serves as a tuning parameter for individual predictors.

lambda2

a user-supplied sequence of \(\lambda_{2}\) values, which serves as a tuning parameter for interactions.

nfolds

the number of folds for cross-validation.

maxits

the maximum number of iterations that is used in the estimation algorithm. The default value is 30.

corre

the working correlation structure that is used in the estimation algorithm. interep provides three choices for the working correlation structure: "AR-1", "independece" and "exchangeable".

Value

an object of class "cv.interep" is returned, which is a list with components:

lam1

the optimal \(\lambda_{1}\).

lam2

the optimal \(\lambda_{2}\).

Details

When dealing with predictors with both main effects and interactions, this function returns two optimal tuning parameters, \(\lambda_{1}\) and \(\lambda_{2}\); when there are only main effects in the predictors, this function returns \(\lambda_{1}\), which is the optimal tuning parameter for individual predictors containing main effects.

References

Zhou, F., Wang, W., Jiang, Y. and Wu, C. (2018+). Variable selection for interactions in longitudinal lipidomics studies.

Wu, C., Zhong, P. & Cui, Y. (2018). Additive varying-coefficient model for nonlinear gene-environment interactions. Statistical Applications in Genetics and Molecular Biology, 17(2)

Wu, C., Jiang, Y., Ren, J., Cui, Y. and Ma, S. (2018). Dissecting gene-environment interactions: a penalized robust approach accounting for hierarchical structures. Statistics in Medicine, 37:437<U+2013>456

Wu, C., Shi, X., Cui, Y. and Ma, S. (2015) A penalized robust semiparametric approach for gene-environment interactions. Statistics in Medicine, 34 (30): 4016<U+2013>4030

Wu, C., Cui, Y. and Ma, S. (2014) Integrative analysis of gene-environment interactions under a multi-response partially linear varying coefficient model. Statistics in Medicine, 33 (28): 4988<U+2013>4498

Wu, C. and Cui Y. (2013) A novel method for identifying nonlinear gene-environment interactions in case-control association studies. Human Genetics, 132 (12): 1413<U+2013>1425