diffHaplo {pegas} | R Documentation |
Comparison Between Two Haplotypes
Description
This function compares two haplotypes and returns a summary of the differences.
Usage
diffHaplo(h, a = 1, b = 2, strict = FALSE, trailingGapsAsN = TRUE)
Arguments
h |
an object of class |
a , b |
two integers (or character strings) giving the indices (or labels) of the two haplotypes to be compared. |
strict |
a logical value; if |
trailingGapsAsN |
a logical value; if |
Details
The options strict
and trailingGapsAsN
are passed to
seg.sites
.
Value
a data frame with three columns named pos
(position of the
differences) and the labels of the two haplotypes compared.
Author(s)
Emmanuel Paradis
See Also
Examples
data(woodmouse)
h <- haplotype(woodmouse)
diffHaplo(h) # compares the 1st and 2nd haplotypes
diffHaplo(h, 1, 3)
diffHaplo(h, "I", "III") # same than above but using labels
[Package pegas version 1.3 Index]