Learn R Programming

ctl (version 1.0.0-10)

plot.CTLscan: Plot CTL results as bar, line or GWAS plot.

Description

Plot the CTL results for a genome scan (the output of CTLscan) as a barplot, curved line or GWAS plot.

Usage

# S3 method for CTLscan
plot(x, mapinfo = NULL, type = c("barplot","gwas","line"), 
onlySignificant = TRUE, significance = 0.05, gap = 25, plot.cutoff = FALSE, 
do.legend=TRUE, legend.pos = "topleft", cex.legend=1.0, ydim=NULL, 
ylab="-log10(P-value)", ...)

Value

None.

Arguments

x

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

mapinfo

The mapinfo matrix with 3 columns: "Chr" - the chromosome number, "cM" - the location of the marker in centiMorgans and the 3rd column "Mbp" - The location of the marker in Mega basepairs. If supplied the marker names (rownames) should match those in the CTLobject.

type

Type of plot: Summed barplot, GWAS style plot or a basic line plot.

onlySignificant

Plot only the significant contributions to the CTL profile.

significance

Significance threshold for setting a genomewide FDR.

gap

Gap in Cm between chromosomes.

plot.cutoff

Adds a line at -log10(significance) and adds a legend showing the significance level.

do.legend

Adds a legend showing which phenotypes contribute to the CTL profile.

legend.pos

Position of the legend in the plot window.

cex.legend

Maginification of the text in the legend.

ydim

Dimension of the y-axis, if NULL then it will be calculated.

ylab

Label for the y-axis.

...

Passed to the function plot when it is called.

Author

Danny Arends Danny.Arends@gmail.com
Maintainer: Danny Arends Danny.Arends@gmail.com

Details

None.

See Also

  • CTLscan - Scan for CTL

  • print.CTLscan - Print a summary of a CTLscan

  • par - Plot parameters

  • colors - Colors used in plotting

Examples

Run this code
  library(ctl)
  data(ath.result)       # Arabidopsis thaliana results
  data(ath.metabolites)  # Arabidopsis thaliana data (phenotypes, genotypes and mapinfo

  plot(ath.result[[3]])
  plot(ath.result[[2]], mapinfo = ath.metab[[3]])
  plot(ath.result[[1]], mapinfo = ath.metab[[3]])
  plot(ath.result[[3]], mapinfo = ath.metab[[3]])
  plot(ath.result[[3]], mapinfo = ath.metab[[3]], type="gwas")
  plot(ath.result[[3]], mapinfo = ath.metab[[3]], type="line")

Run the code above in your browser using DataLab