plot.scantwo {qtl}R Documentation

Plot LOD scores for a two-dimensional genome scan

Description

Plot the results of a two-dimensional, two-QTL genome scan.

Usage

## S3 method for class 'scantwo'
plot(x, chr, incl.markers=FALSE, zlim, lodcolumn=1,
     lower = c("full", "add", "cond-int", "cond-add", "int"),
     upper = c("int", "cond-add", "cond-int", "add", "full"),
     nodiag=TRUE, contours=FALSE, main, zscale=TRUE, point.at.max=FALSE,
     col.scheme = c("viridis", "redblue","cm","gray","heat","terrain","topo"),
     gamma=0.6, allow.neg=FALSE, alternate.chrid=FALSE, ...)

Arguments

x

An object of class "scantwo", as output by scantwo.

chr

Optional vector indicating the chromosomes to plot. This should be a vector of character strings referring to chromosomes by name; numeric values are converted to strings. Refer to chromosomes with a preceding - to have all chromosomes but those considered. A logical (TRUE/FALSE) vector may also be used.

incl.markers

If FALSE, plot LOD scores on an evenly spaced grid (not including the results at the markers).

zlim

A vector of length 2 (optional), indicating the z limits for the lower-right and upper-left triangles, respectively. If one number is given, the same limits are used for both triangles. If zlim is missing, the maximum limits are used for each.

lodcolumn

If the scantwo results contain LOD scores for multiple phenotypes, this argument indicates which to use in the plot.

lower

Indicates which LOD scores should be plotted in the lower triangle. See the details below.

upper

Indicates which LOD scores should be plotted in the upper triangle. See the details below.

nodiag

If TRUE, suppress the plot of the scanone output (which is normally along the diagonal.)

contours

If TRUE, add a contour to the plot at 1.5-LOD below its maximum, using a call to contour. If a numeric vector, contours are drawn at these values below the maximum LOD.

main

An optional title for the plot.

zscale

If TRUE, a color scale is plotted at the right.

point.at.max

If TRUE, plot an X at the maximum LOD.

col.scheme

Name of color pallet. The default is "viridis"; see Option D at https://bids.github.io/colormap/

gamma

Parameter affecting range of colors when col.scheme="gray" or ="redblue".

allow.neg

If TRUE, allow the plot of negative LOD scores; in this case, the z-limits are symmetric about 0. This option is chiefly to allow a plot of difference between LOD scores from different methods, calculated via -.scantwo.

alternate.chrid

If TRUE and more than one chromosome is plotted, alternate the placement of chromosome axis labels, so that they may be more easily distinguished.

...

Ignored at this point.

Details

Uses image to plot a grid of LOD scores. The particular LOD scores plotted in the upper-left and lower-right triangles are selected via upper and lower, respectively. By default, the upper-left triangle contains the epistasis LOD scores ("int"), and the lower-right triangle contains the LOD scores for the full model ("full"). The diagonal contains either all zeros or the main effects LOD scores (from scanone).

The scantwo function calculates, for each pair of putative QTLs, (q_1,q_2), the likelihood under the null model L_0, the likelihood under each of the single-QTL models, L(q_1) and L(q_2), the likelihood under an additive QTL model, L_a(q_1,q_2), and the likelihood under a full QTL model (including QTL-QTL interaction), L_f(q_1,q_2).

The five possible LOD scores that may be plotted are the following. The epistasis LOD scores ("int") are LOD_i = \log_{10} L_f(q_1,q_2) - \log_{10} L_a(q_1,q_2).

The full LOD scores ("full") are LOD_f = \log_{10} L_f(q_1,q_2) - \log_{10} L_0.

The additive LOD scores ("add") are LOD_a = \log_{10} L_a(q_1,q_2) - \log_{10} L_0.

In addition, we may calculate, for each pair of chromosomes, the difference between the full LOD score and the maximum single-QTL LOD scores for that pair of chromosomes ("cond-int").

Finally, we may calculate, for each pair of chromosomes, the difference between the additive LOD score and the maximum single-QTL LOD scores for that pair of chromosomes ("cond-add").

If a color scale is plotted (zscale=TRUE), the axis on the left indicates the scale for the upper-left triangle, while the axis on the right indicates the scale for the lower-right triangle. Note that the axis labels can get screwed up if you change the size of the figure window; you'll need to redo the plot.

Value

None.

Output of addpair

Note that, for output from addpair in which the new loci are indicated explicitly in the formula, the summary provided by plot.scantwo is somewhat special. In particular, the lower and upper arguments are ignored.

In the case that the formula used in addpair was not symmetric in the two new QTL, the x-axis in the plot corresponds to the first of the new QTL and the y-axis corresponds to the second of the new QTL.

Author(s)

Hao Wu; Karl W Broman, broman@wisc.edu; Brian Yandell

See Also

scantwo, summary.scantwo, plot.scanone, -.scantwo

Examples

data(hyper)

hyper <- calc.genoprob(hyper, step=5)


# 2-d scan by EM and by Haley-Knott regression
out2.em <- scantwo(hyper, method="em")
out2.hk <- scantwo(hyper, method="hk")

# plot epistasis and full LOD scores
plot(out2.em)

# plot cond-int in upper triangle and full in lower triangle
#     for chromosomes 1, 4, 6, 15
plot(out2.em, upper="cond-int", chr=c(1,4,6,15))

# plot cond-add in upper triangle and add in lower triangle
#     for chromosomes 1, 4
plot(out2.em, upper="cond-add", lower="add", chr=c(1,4))

# plot the differences between the LOD scores from Haley-Knott
#     regression and the EM algorithm
plot(out2.hk - out2.em, allow.neg=TRUE)

[Package qtl version 1.66 Index]