cash-plotLG: BC, FS and IC method: Heatmap of 2-point rf and LOD estimates...

$plotLGR Documentation

BC, FS and IC method: Heatmap of 2-point rf and LOD estimates from linkage group order

Description

Method for plotting 2-point recombination fraction and LOD score estimates when the SNPs are ordered according to the linkage groups.

Usage

BCobj$plotLG(parent  = "maternal", LG=NULL, mat="rf", filename=NULL, interactive=TRUE, what = NULL)
FSobj$plotLG(parent  = "maternal", LG=NULL, mat="rf", filename=NULL, interactive=TRUE, what = NULL)
ICobj$plotLG(LG=NULL, mat="rf", filename=NULL, interactive=TRUE)

Arguments

mat

Charater value for the matrix to be plotted. "rf" plots the matrix of 2-point recombination fractions while "LOD" plots the matrix of 2-point LOD scores.

LG

Integer vector giving the indices of the linkage groups to be plotted.

filename

Character value giving the name of the file to save the plot to. If NULL, the plot is displayed in the graphics window and not saved to a file.

parent

Character value specifying whether the SNPs segreagting in the maternal parent should be plotted ("maternal"), or whether whether the SNPs segreagting in the paternal parent should be plotted ("paternal"), or whether all the SNPs should be plotted ("both").

interative

Logical value. If TRUE then an interactive plot is produced, otherwise a standard base R plot is used.

what

Character vector specifying which list of linkage groups to plot (see details).

Details

This function plots the heatmap of the matrix of 2-point recombination fraction estimates (or 2-point LOD scores) as computed from the $rf_2pt function.

The interactive plot (interactive = TRUE) is produced via the plot_ly function. Note, however, that the interactive plot only works for a relatively small number of SNPs (about 1000 is maximum). Nevertheless, one can still plot each linkage group (using the LG argument) provided there are not too many SNPs in the linkage group.

BC object: When what = "LG-pts", the pseudo-testcross linkage groups created via the $createLG function will be plotted. On the other hand, if what = "LG-bi", then the pseudo-testcross linkage groups with BI SNPs created from the $addBIsnps function will be plotted. When what = NULL, the pseudo-testcross linkage groups with BI SNPs will be plotted if available, otherwise the pseudo-testcross linkage groups will be plotted.

FS object: When what = "LG-pts", the pseudo-testcross linkage groups created via the $createLG function will be plotted. On the other hand, if what = "LG-comb", then the combined linkage groups created from the $addBIsnps function will be plotted. When what = NULL, the combined linkage groups will be plotted if available, otherwise the pseudo-testcross linkage groups will be plotted.

Author(s)

Timothy P. Bilton

See Also

BC, FS, IC

Examples

## Simulate some sequencing data
set.seed(6745)
config <- list(replicate(2, sample(c(1,2,4), size=30, replace=TRUE), simplify=FALSE))
F1data <- simFS(0.01, config=config, meanDepth=10, nInd=50)
## Compute 2-point recombination fractions
F1data$rf_2pt()
## create paternal and maternal linkage groups
F1data$createLG()

## Plot the linkage groups
F1data$plotLG()

## Plot the linkage groups: suppress interactive plot 
F1data$plotLG(interactive = FALSE)

tpbilton/GUSMap documentation built on Feb. 22, 2025, 12:27 p.m.