LDtools package for R computes measures and plots of LD for detecting selection. Examples of these tools for LD analysis can be found in the following article:
Williams F, Meenagh A, Single R, McNally M, Kelly P, Nelson M_P, Meyer D, Lancaster A, Thomson G, and Middleton D. High resolution HLA-DRB1 identification of a Caucasian population. Human Immunology, 2004; 65(1): 66-77. http://www.ncbi.nlm.nih.gov/pubmed/14700598
Abstract info about DPA ...
The DPAplot function generates plots and summary measures realted to Disequilibrium Pattern Analysis (DPA), as follows:
dpa.results <- DPAplot(dat=dat, y.threshold=.005, r2.threshold=.70, tolerance=.01)
Parameter dat is a data.frame with 5 required variables:
Parameter tolerance is a threshold for the sum of the haplotype frequencies. If the sum of the haplotype frequencies is greater than 1+tolerance or less than 1-tolerance an error is returned.
Parameter y.threshold is a threshold for plotting based on the maximum expected freq. If the maximum expected freq is less than y.threshold, no plot is created (default=0.005)
Parameter r2.threshold A threshold for plotting based on the fit of the regression line. If the R-squared value is less than r2.threshold, no plot is created (default=0.75)
The function returns a dataframe (in the above example dpa.results) with the following components:
This is an example of DPA using haplotype frequencies from Williams et al. (2004)
data(NIreland.freqs)
loc1 <- "A"
loc2 <- "B"
temp.dat <- NIreland.freqs[NIreland.freqs$locus1==loc1 & NIreland.freqs$locus2==loc2,]
DPAplot(dat=temp.dat, y.threshold=.005, r2.threshold=.70)
#Create a file with several DPA plots for the chosen loci
postscript(file="Irish_A-B.ps", horizontal=T)
par(mfrow=c(2,2))
DPAplot(dat=temp.dat, y.threshold=.005, r2.threshold=.70)
dev.off()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.