| gweis.mem | R Documentation |
Routine to allocate memory needed to perform a GWEIS.
gweis.mem(gemdl, subids, tests, gomdl = NULL)
gemdl |
The results from glm for the gene-environment model. This model contains the outcome and all covariates of interest with the last covariate listed in the model being the covaraiate that the gene interaction is being tested for. |
subids |
A character vector of subject IDs that line up with the data that was used in the models that are passed to this routine |
tests |
The list of tests to perform. These can be any combination of the following values "bg_go", "bg_ge", "bg_gxe", "bgxe", "joint", "bg_eg", "bg_case", "bg_ctrl" |
gomdl |
The results from glm for the gene-only model. This model
contains the outcome and all the covariates except the covariate that
the gene interaction is being tested for. Required (non-NULL) when
|
List containing allocated memory to perform the specified GWEIS.
This value is passed to the rungweis routine. Returns 1 if
any value in tests is not a recognised test name.
## Not run:
bdinfo <- BinaryDosage::getbdinfo(system.file("extdata", "gendata.bdose",
package = "GxEScanR"))
subdata <- readRDS(system.file("extdata", "subdata.rds", package = "GxEScanR"))
subdata <- subdata[complete.cases(subdata), ]
subdata <- subdata[subdata$subid %in% bdinfo$samples$sid, ]
linearmodel <- glm(y_linear ~ x2 + x1, data = subdata)
linearmem <- gweis.mem(gemdl = linearmodel,
subids = subdata$subid,
tests = c("bg_ge", "bg_gxe", "bgxe", "joint"))
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.