Daniel:Notebook/Haplotyping/ConsistentPairs

From ZhangLabWiki
Revision as of 18:56, 11 December 2015 by >Djacobse (→‎The Method)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Comparing Haplotypes Using the Consistent Pairs Method

Back to Notebook

The Method

The consistent pairs method is derived from the 2013 BMC paper by Matsumoto and Kiryu. The method is a tool for evaluating the consistency of haplotypes. Basically, we can define a consistent pair as one whose SNPs are phased in the same manner (e.g. 00/11 and 00/11). An inconsistent pair is one who has not been phased in a similar manner. For better explanation, see the figure below taken from the 2013 paper.

File:ConsistentPairs.png

We can therefore define precision as CP/(CP+IP). An example of calculating CP+IP can be found below.

File:Precision.png


The paper also defines recall as the number of pairs found (CP+IP) divided by the total number of pairs available (in the VCF). This is especially important when considering the number of blocks. By splitting the results into multiple blocks, the number of pairs drastically reduces. This means that recall is a valuable metric when evaluating haplotypes, as it describes the connectivity quality of the data. In the picture below, I take the same data from the precision figure (and the 2013 paper) and split the data into two blocks.

File:Recall haplotyping 2013BMC.png

The precision actually moves up to one, since although Block2 has 5 inconsistent sites with Block1, the pairs remain entirely consistent. Therefore, there are no inconsistent pairs in either haplotype. However, the recall in this example is drastically reduced to 0.45 (the recall in the first example is 1).

Recall can actually be described for individual runs, as well as a combined recall for evaluating two files at once. Precision always requires two files to compare, and since, unlike in the BMC paper, there is no gold standard for my data, I simply use precision as a measure of difference between any two haplotypes. Normally I report this as 1-precision, or precision distance.