Learn R Programming

synbreed (version 0.12-9)

plotNeighbourLD: Plot neighbour linkage disequilibrium

Description

A function to visualize Linkage Disequilibrium estimates between adjacent markers.

Usage

plotNeighbourLD(LD, gpData, dense=FALSE, nMarker = TRUE,
                centr=NULL, file=NULL, fileFormat="pdf", ...)

Arguments

LD

object of class LDmat, i.e the output of function pairwiseLD using argument type="matrix".

gpData

object of class gpData with object map or a data.frame with columns 'chr' (specifying the chromosome of the marker) and 'pos' (position of the marker within chromosome measured with genetic or physical distances)

dense

logical. Should density visualization for high-density genetic maps be used?

nMarker

logical. Print number of markers for each chromosome?

centr

numeric vector. Positions for the centromeres in the same order as chromosomes in map. If "maize", centromere positions of maize in Mbp are used.

file

Optionally a path to a file where the plot is saved to

fileFormat

character. At the moment two file formats are supported: pdf and png. Default is "pdf".

further graphical arguments for function plot

Value

Plot of neighbour LD along each chromosome. One chromosome is displayed from the first to the last marker.

Details

The plot is similar to plotGenMap with the option dense=TRUE, but here the LD between adjacent markers is plotted along the chromosomes.

See Also

plotGenMap, pairwiseLD

Examples

Run this code
# NOT RUN {
library(synbreedData)
data(maize)
maize2 <-codeGeno(maize)
LD <- pairwiseLD(maize2,chr=1:10,type="matrix")
plotNeighbourLD(LD,maize2,nMarker=FALSE)
# }

Run the code above in your browser using DataLab