plot.haplen {rehh} | R Documentation |
Plot the length of extended haplotypes around a focal marker
Description
Plot the length of extended haplotype around a focal marker.
Usage
## S3 method for class 'haplen'
plot(
x,
allele = NA,
group_by_allele = TRUE,
order_by_length = FALSE,
col = c("blue", "red", "violet", "orange"),
mrk.col = "gray",
lwd = 1,
hap.names = NULL,
cex.lab = 1,
family.lab = "",
offset.lab = 0.5,
pos.lab = "left",
legend = NA,
legend.xy.coords = "automatic",
...
)
Arguments
x |
an object of class |
allele |
if |
group_by_allele |
logical. If |
order_by_length |
if |
col |
color for each allele (as coded internally). |
mrk.col |
color of the vertical line at the focal marker position. |
lwd |
line width. |
hap.names |
a vector containing the names of chromosomes. |
cex.lab |
relative letter size of labels. See |
family.lab |
font family for labels. See |
offset.lab |
offset of labels. See |
pos.lab |
position of haplotype labels. Either |
legend |
legend text. |
legend.xy.coords |
if |
... |
other parameters to be passed to |
See Also
Examples
#example haplohh object (280 haplotypes, 1424 SNPs)
#see ?haplohh_cgu_bta12 for details
data(haplohh_cgu_bta12)
#plotting length of extended haplotypes for both ancestral and derived allele
#of the marker "F1205400"
#which displays a strong signal of selection
f <- calc_furcation(haplohh_cgu_bta12, mrk = "F1205400")
h <- calc_haplen(f)
plot(h)
plot(h, hap.names = hap.names(haplohh_cgu_bta12), cex.lab = 0.3)