This package implements aGE tests, which is a data-adaptive set-based gene-environment interaction (GxE) test, specifically designed for rare variants.
The model is $g(\mu_i)= X_i\beta_0+ G_i\beta_1 + S_i\beta_2$,
where $g(\cdot)$ is the link function, $X_i$ is the covariate matrix including the environmental variable, $G_i$ is the $q \times q$ genotype matrix and $S_i$ is the $q \times q$ GxE interaction matrix.
The interaction test, the null hypothesis is that $\beta_2=[\beta_{21},\ldots,\beta_{2q}]^T=[0,\ldots,0]^T.$
For joint test,the null hypothesis is that $\beta_1=\beta_2=[0,\ldots,0]^T.$
Other than CRAN, github can be checked for most recent update.
setwd('local folder') ``` * Step 3: install the package in R ```r install.packages('aGE.version.tar.gz',repos=NULL,type='source')
Two functions are available: aGE and aGE.joint. The former performs adaptive GxE test and the later performs joint test for both genetic main and GxE effects. The details of inputs of the functions can be foound by typing ?aGE and ?aGE.joint in R command line.
A simple demonstration of the usage and output of the package. The simulation method is recommended to use for sample size $>$ 500.
library(aGE) set.seed(12345) phenotype <- c(rep(1,50),rep(0,50)) genotype <- data.frame(g1=sample(c(rep(1,10),rep(0,90))),g2=sample(c(rep(1,5), rep(0,95)))) covariates <- data.frame(Envir=rnorm(100), Age=rnorm(100,60,5)) exD <- list(Y=phenotype, G=genotype, X=covariates) aGE(Y=exD$Y, G=exD$G, cov=exD$X, model='binomial', nonparaE=F, stepwise=F) aGE.joint(Y=exD$Y, G=exD$G, cov=exD$X, model='binomial', nonparaE=T, DF=5, method='Simulation')
The stepwise option in aGE function is suggested for real-data GxE analysis, where a high genome-wide significant level is required. It performs Monte Carlo method with the number of permutation (B) equals 1,000 and then increase B gradually if small p-values are observed.
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.