marker2covar:
Create a covariate from a genetic marker.
Description
Covariates can be derived from either genetic markers or phenotypic values. This function generates covariates from genetic markers. These covariates are treated distinctly from those generated from phenotypic values. For example, they are used in kinship calculations. The are also plotted in their original positions, rather than placed at the end as the phenotypic covariates are.
The object in which all results are stored. See read.population.
geno.obj
The object in which the genotype matrix and marker information are stored. See read.geno.
singlescan.obj
The results of the singlescan generated by singlescan
covar.thresh
Genetic markers can be selected as covariates based on their standardized effect sizes in the singlescan. covar.thresh indicates the standardized effect size threshold for generating covariates. All markers with standardized effect sizes above this value will be converted to covariates.
markers
A vector of names or numbers indicating which genetic markers should be converted to covariates.
Value
Returns the data object with two additional elements.
g.covar.table
A table of the covariates and their values.
g.covar
A table with positional information for each covariate. The table contains three rows indicating each covariate's name, chromosome, and chromosomal position.