qtl (version 1.39-5)

calc.genoprob: Calculate conditional genotype probabilities

Description

Uses the hidden Markov model technology to calculate the probabilities of the true underlying genotypes given the observed multipoint marker data, with possible allowance for genotyping errors.

Usage

calc.genoprob(cross, step=0, off.end=0, error.prob=0.0001, map.function=c("haldane","kosambi","c-f","morgan"), stepwidth=c("fixed", "variable", "max"))

Arguments

cross
An object of class cross. See read.cross for details.
step
Maximum distance (in cM) between positions at which the genotype probabilities are calculated, though for step = 0, probabilities are calculated only at the marker locations.
off.end
Distance (in cM) past the terminal markers on each chromosome to which the genotype probability calculations will be carried.
error.prob
Assumed genotyping error rate used in the calculation of the penetrance Pr(observed genotype | true genotype).
map.function
Indicates whether to use the Haldane, Kosambi or Carter-Falconer map function when converting genetic distances into recombination fractions.
stepwidth
Indicates whether the intermediate points should with fixed or variable step sizes. We recommend using "fixed"; "variable" is included for the qtlbim package (http://www.ssg.uab.edu/qtlbim). The "max" option inserts the minimal number of intermediate points so that the maximum distance between points is step.

Value

The input cross object is returned with a component, prob, added to each component of cross$geno. prob is an array of size [n.ind x n.pos x n.gen] where n.pos is the number of positions at which the probabilities were calculated and n.gen = 3 for an intercross, = 2 for a backcross, and = 4 for a 4-way cross. Attributes "error.prob", "step", "off.end", and "map.function" are set to the values of the corresponding arguments, for later reference (especially by the function calc.errorlod).

Details

Let $O[k]$ denote the observed marker genotype at position $k$, and $g[k]$ denote the corresponding true underlying genotype.

We use the forward-backward equations to calculate $ a[k][v] = log Pr(O[1], \ldots, O[k], g[k] = v)$ and $ b[k][v] = log Pr(O[k+1], \ldots, O[n] | g[k] = v)$

We then obtain $ Pr(g[k] | O[1], \ldots, O[n] = exp(a[k][v] + b[k][v]) / s$ where $ s = sum_v exp(a[k][v] + b[k][v])$

In the case of the 4-way cross, with a sex-specific map, we assume a constant ratio of female:male recombination rates within the inter-marker intervals.

References

Lange, K. (1999) Numerical analysis for statisticians. Springer-Verlag. Sec 23.3.

Rabiner, L. R. (1989) A tutorial on hidden Markov models and selected applications in speech recognition. Proceedings of the IEEE 77, 257--286.

See Also

sim.geno, argmax.geno, calc.errorlod

Examples

Run this code
data(fake.f2)
fake.f2 <- calc.genoprob(fake.f2, step=2, off.end=5)

data(fake.bc)
fake.bc <- calc.genoprob(fake.bc, step=0, off.end=0, err=0.01)

Run the code above in your browser using DataLab