View source: R/calc.locallod.R
calc.locallod | R Documentation |
For gene expression data with physical positions of the genes, calculate the LOD score at those positions to assess evidence for local eQTL.
calc.locallod( cross, pheno, pmark, addcovar = NULL, intcovar = NULL, verbose = TRUE, n.cores = 1 )
cross |
An object of class |
pheno |
A data frame of phenotypes (generally gene expression data), stored as individuals x phenotypes. The row names must contain individual identifiers. |
pmark |
Pseudomarkers that are closest to the genes in |
addcovar |
Additive covariates passed to |
intcovar |
Interactive covariates passed to |
verbose |
If TRUE, print tracing information. |
n.cores |
Number of CPU cores to use in the calculations. With
|
cross
and pheno
must contain exactly the same individuals in
the same order. (Use findCommonID()
to line them up.)
We consider the expression phenotypes in batches: those whose closest pseudomarker is the same.
We use Haley-Knott regression to calculate the LOD scores.
Actually, we use a bit of a contortion of the data to force the
qtl::scanone()
function in R/qtl to calculate the LOD score at a
single position.
We omit any transcripts that map to the X chromosome; we can only handle autosomal loci for now.
A vector of LOD scores. The names indicate the gene names (columns in
pheno
).
Karl W Broman, broman@wisc.edu
find.gene.pseudomarker()
, plotEGclass()
,
findCommonID()
, disteg()
data(f2cross, expr1, genepos, pmap) library(qtl) # calc QTL genotype probabilities f2cross <- calc.genoprob(f2cross, step=1) # find nearest pseudomarkers pmark <- find.gene.pseudomarker(f2cross, pmap, genepos, "prob") # line up f2cross and expr1 id <- findCommonID(f2cross, expr1) # calculate LOD score for local eQTL locallod <- calc.locallod(f2cross[,id$first], expr1[id$second,], pmark)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.