Learn R Programming

qtl (version 1.39-5)

addpair: Scan for an additional pair of QTL in a multiple-QTL model

Description

Scan for an additional pair of QTL in the context of a multiple QTL model.

Usage

addpair(cross, chr, pheno.col=1, qtl, covar=NULL, formula, method=c("imp","hk"), model=c("normal", "binary"), incl.markers=FALSE, verbose=TRUE, tol=1e-4, maxit=1000, forceXcovar=FALSE)

Arguments

cross
An object of class cross. See read.cross for details.
chr
Optional vector indicating the chromosomes to be scanned. If missing, all chromosomes are scanned. Refer to chromosomes by name. Refer to chromosomes with a preceding - to have all chromosomes but those considered. A logical (TRUE/FALSE) vector may also be used.
pheno.col
Column number in the phenotype matrix to be used as the phenotype. One may also give a character string matching a phenotype name. Finally, one may give a numeric vector of phenotypes, in which case it must have the length equal to the number of individuals in the cross, and there must be either non-integers or values < 1 or > no. phenotypes; this last case may be useful for studying transformations.
qtl
An object of class qtl, as output from makeqtl.
covar
A matrix or data.frame of covariates. These must be strictly numeric.
formula
An object of class formula indicating the model to be fitted. (It can also be the character string representation of a formula.) QTLs are referred to as Q1, Q2, etc. Covariates are referred to by their names in the data frame covar. If the new QTL are not included in the formula, a two-dimensional scan as in scantwo is performed.
method
Indicates whether to use multiple imputation or Haley-Knott regression.
model
The phenotype model: the usual model or a model for binary traits
incl.markers
If FALSE, do calculations only at points on an evenly spaced grid. If calc.genoprob or sim.geno were run with stepwidth="variable" or stepwidth="max", we force incl.markers=TRUE.
verbose
If TRUE, display information about the progress of calculations. If verbose is an integer > 1, further messages from scanqtl are also displayed.
tol
Tolerance for convergence for the binary trait model.
maxit
Maximum number of iterations for fitting the binary trait model.
forceXcovar
If TRUE, force inclusion of X-chr-related covariates (like sex and cross direction).

Value

An object of class scantwo, as produced by scantwo. If neither of the new QTL were indicated in the formula, the result is just as in scantwo, though with LOD scores relative to the base model (omitting the new QTL). Otherwise, the results are contained in what would ordinarily be in the full and additive LOD scores, with the additive LOD scores corresponding to the case that the first of the new QTL is to the left of the second of the new QTL, and the full LOD scores corresponding to the case that the first of the new QTL is to the right of the second of the new QTL. Because the structure of the LOD scores in this case is different from those output by scantwo, we include, in this case, an attribute "addpair"=TRUE. (We also require results of single-dimensional scans, omitting each of the two new QTL from the formula, one at a time; these are included as attributes "lod.minus1" and "lod.minus2".) The results are then treated somewhat differently by summary.scantwo, max.scantwo, and plot.scantwo. See the Details section.

Details

The formula is used to specified the model to be fit. In the formula, use Q1, Q2, etc., or q1, q2, etc., to represent the QTLs, and the column names in the covariate data frame to represent the covariates.

We enforce a hierarchical structure on the model formula: if a QTL or covariate is in involved in an interaction, its main effect must also be included.

If neither of the two new QTL are indicated in the formula, we perform a two-dimensional scan as in scantwo. That is, for each pair of QTL positions, we fit two models: two additive QTL added to the formula, and two interacting QTL added to the formula.

If the both of the new QTL are indicated in the formula, that particular model is fit, with the positions of the new QTL allowed to vary across the genome. If just one of the QTL is indicated in the formula, a main effect for the other is added, and that particular model is fit, again with the positions of both QTL varying. Note that in this case the LOD scores are not analogous to those produced by scantwo. Thus, there slightly modified forms for the plots (produced by plot.scantwo) and summaries (produced by summary.scantwo and max.scantwo). In the plot, the x-axis is to be interpreted as the position of the first of the new QTL, and the y-axis is to be interpreted as the position of the second of the new QTL. In the summaries, we give the single best pair of positions on each pair of chromosomes, and give LOD scores comparing that pair of positions to the base model (without each of these QTL), and to the base model plus one additional QTL on one or the other of the chromosomes.

References

Haley, C. S. and Knott, S. A. (1992) A simple regression method for mapping quantitative trait loci in line crosses using flanking markers. Heredity 69, 315--324.

Sen, Ś. and Churchill, G. A. (2001) A statistical framework for quantitative trait mapping. Genetics 159, 371--387.

See Also

addint, addqtl, fitqtl, makeqtl, scanqtl, refineqtl, makeqtl, scantwo, addtoqtl

Examples

Run this code
# A totally contrived example to show some of what you can do

# simulate backcross data with 3 chromosomes (names "17", "18", "19")
#   one QTL on chr 17 at 40 cM
#   one QTL on chr 18 at 30 cM
#   two QTL on chr 19, at 10 and 40 cM
data(map10)
model <- rbind(c(1,40,0), c(2,30,0), c(3,10,0), c(3,40,0))
## Not run: fakebc <- sim.cross(map10[17:19], model=model, type="bc", n.ind=250)


# het at QTL on 17 and 1st QTL on 19 increases phenotype by 1 unit
# het at QTL on 18 and 2nd QTL on 19 decreases phenotype by 1 unit
qtlgeno <- fakebc$qtlgeno
phe <- rnorm(nind(fakebc))
w <- qtlgeno[,1]==2 & qtlgeno[,3]==2
phe[w] <- phe[w] + 1
w <- qtlgeno[,2]==2 & qtlgeno[,4]==2
phe[w] <- phe[w] - 1
fakebc$pheno[,1] <- phe

## Not run: fakebc <- calc.genoprob(fakebc, step=2, err=0.001)


# base model has QTLs on chr 17 and 18
qtl <- makeqtl(fakebc, chr=c("17", "18"), pos=c(40,30), what="prob")

# scan for an additional pair of QTL, one interacting with the locus
#     on 17 and one interacting with the locus on 18
out.ap <- addpair(fakebc, qtl=qtl, formula = y~Q1*Q3 + Q2*Q4, method="hk")

max(out.ap)
summary(out.ap)
plot(out.ap)

Run the code above in your browser using DataLab