Wrapper to Test a Chromosome with LOCATER and kalis
TestLoci.RdA simple wrapper function designed to allow users to easliy run LOCATER in conjunction with kalis.
Arguments
- y
 a
nxmmatrix of m quantitative phenotypes (one phenotype / column)- pars
 a
kalisParametersobject specifing HMM parameters to the Li and Stephens HMM as returned bykalis::Parameters- target.loci
 a vector of integers specifying index of variants among those cached with
kalis::CacheHaplotypesto be screened with LOCATER- A
 a
nxqmatrix of q background covariates (an intercept – column of 1s – should be included). Just an intercept by default.- test.opts
 a list of testing options that can customized the behavior of
TestLoci(further documentation coming)- verbose
 a logical, if TRUE print progress statements as
TestLociprogresses- num.ckpts
 an integer, the number of checkpoints that can be stored in memory. default = 0. Increasing even to just `2L` or `3L` yields significant speed ups.
- ckpt.first.locus
 a logical, should the first target locus be stored as a checkpoint. Default is FALSE but if the first target locus is very far from start of the cached chromosome, TRUE may yield an acceleration.
- use.forking
 a logical, is multiprocessing by process forking allowed? Some relatively minor acclerations are possible if TRUE, but users should verify that it is safe to launch forked processes on their compute cluster.
- nthreads
 an integer, number of threads available
Value
a data.table with one row per target locus including the following key fields
locus.idx: the index of corresponding variant (corresponding totarget.loci)phenotype: the phenotype tested (given a column index ofy)tot: LOCATER -log10 p-valuesmt: -log10 p-value from single marker testingrd: -log10 p-value returned by running Stable Distillationqform: -log10 p-value returned by quadratic form testing