Description Usage Arguments Value See Also Examples
Implements single marker regressions. The regression model includes all the
covariates specified in the righthandside of the formula
plus one
column of the genotypes at a time. The data from the association tests is
obtained from a BGData
object.
1 2 3 
formula 
The formula for the GWAS model without including the marker, e.g.

data 
A 
method 
The regression method to be used. Currently, the following methods are
implemented: 
i 
Indicates which rows of the genotypes should be used. Can be integer, boolean, or character. By default, all rows are used. 
j 
Indicates which columns of the genotypes should be used. Can be integer, boolean, or character. By default, all columns are used. 
chunkSize 
The number of columns of the genotypes that are brought into physical
memory for processing per core. If 
nCores 
The number of cores (passed to 
verbose 
Whether progress updates will be posted. Defaults to 
... 
Additional arguments for chunkedApply and regression method. 
The same matrix that would be returned by coef(summary(model))
.
filebackedmatrices
for more information on filebacked
matrices. multilevelparallelism
for more information on
multilevel parallelism. BGDataclass
for more information on
the BGData
class. lsfit
,
lm
, lm.fit
,
glm
, lmer
, and
SKAT
for more information on regression methods.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25  # Restrict number of cores to 1 on Windows
if (.Platform$OS.type == "windows") {
options(mc.cores = 1)
}
# Load example data
bg < BGData:::loadExample()
# Perform a single marker regression
res1 < GWAS(formula = FT10 ~ 1, data = bg)
# Draw a Manhattan plot
plot(log10(res1[, 4]))
# Use lm instead of lsfit (the default)
res2 < GWAS(formula = FT10 ~ 1, data = bg, method = "lm")
# Use glm instead of lsfit (the default)
y < pheno(bg)$FT10
pheno(bg)$FT10.01 < y > quantile(y, 0.8, na.rm = TRUE)
res3 < GWAS(formula = FT10.01 ~ 1, data = bg, method = "glm")
# Perform a single marker regression on the first 50 markers (useful for
# distributed computing)
res4 < GWAS(formula = FT10 ~ 1, data = bg, j = 1:50)

Loading required package: BEDMatrix
Loading required package: LinkedMatrix
Loading required package: symDMatrix
Loading chromosomes as .bed files...
Extracting phenotypes from .fam file, assuming that the .fam file of the first BEDMatrix instance is representative of all the other nodes...
Extracting map from .bim files...
Merging alternate phenotype file...
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.