1 / 27

A Linear-Time Algorithm for the Perfect Phylogeny Haplotyping (PPH) Problem

A Linear-Time Algorithm for the Perfect Phylogeny Haplotyping (PPH) Problem. Zhihong Ding, Vladimir Filkov, Dan Gusfield Department of Computer Science University of California, Davis. RECOMB 2005. Haplotypes to Genotypes. Each individual has two “copies” of each chromosome.

javen
Download Presentation

A Linear-Time Algorithm for the Perfect Phylogeny Haplotyping (PPH) Problem

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. A Linear-Time Algorithm for the Perfect Phylogeny Haplotyping (PPH) Problem Zhihong Ding, Vladimir Filkov, Dan Gusfield Department of Computer Science University of California, Davis RECOMB 2005

  2. Haplotypes to Genotypes • Each individual has two “copies” of each chromosome. • At each site, each chromosome has one of two states denoted by 0 and 1 • From haplotypes to genotypes: For each site of an individual, if both haplotypes have state 0, then the genotype has state 0. Same rule for state 1. If two haplotypes have state 0 and 1, or 1 and 0, then the state of the genotype is 2.

  3. Haplotypes to Genotypes Sites: 1 2 3 4 5 6 7 8 9 0 1 1 1 0 0 1 1 0 1 1 0 1 0 0 1 0 0 Two haplotypes per individual Merge the haplotypes Genotype for the individual 2 1 2 1 0 0 1 2 0

  4. Genotypes to Haplotypes For each site, if the genotype has state 0 or 1, then the two haplotypes must have states 0, 0 or 1, 1. If the genotype has state 2, the two haplotypes can either have states 0, 1 or 1, 0. 0 1 1 1 0 0 1 1 0 1 1 0 1 0 0 1 0 0 Two haplotypes per individual 2 1 2 1 0 0 1 2 0 Genotype for the individual

  5. Haplotype Inference Problem • For disease association studies, haplotype data is more valuable than genotype data, but haplotype data is harder and more expensive to collect than genotype data. • Haplotype Inference Problem: Given a set of n genotypes, determine the original set of n haplotype pairsthat generated the n genotypes. • NIH leads HAPMAP project to find common haplotypes in the human population.

  6. Haplotype Inference Problem • If the genotype has state 2 at k sites, there are 2k –1 possible explaining haplotype pairs. • How to determine which haplotype pair is the original one generating the genotype? • We need a model of haplotype evolution to help solve the haplotype inference problem.

  7. The Perfect Phylogeny Model of Haplotype Evolution sites 12345 00000 Ancestral haplotype 1 4 Site mutations on edges 3 00010 2 10100 5 10000 01010 01011 Extant haplotypes at the leaves

  8. Assumptions of Perfect Phylogeny Model • No recombination, only mutation. • Infinite-site assumption: one mutation per site.

  9. The Perfect Phylogeny Haplotyping(PPH) Problem Given a set of genotypes, find an explaining set of haplotypes that fits a perfect phylogeny Site 1 2 b 00 a a b c c 01 01 10 10 Genotype matrix 10 Haplotype matrix Perfect phylogeny

  10. Prior Work • Several existing algorithms that solve the PPH problem, but none of them is in linear time. • Our contribution: • A linear time algorithm. • Our implementation is about 250 times faster than the fastest one of previous algorithms for large data set.

  11. A P-Class of PPH Solutions • P-Class: Maximum common subgraph in all PPH solutions • Each P-Class consists of two subtrees root 4 1 2 Sites: 1 2 3 4 5 a b c d 2 2 2 0 0 2 0 0 2 2 2 2 2 0 2 2 0 0 2 0 5 3 b,d Genotypes a,d a,c Genotype Matrix b,c One PPH Solution

  12. P-Class Property of PPH Solutions • All PPH solutions can be obtained by choosing how to flip each P-Class. root Switching points root 1 Switching points 4 5 a,d 1 4 2 2 b,c b,d a,d 5 3 3 b,d a,c b,c a,c One PPH Solution Second PPH Solutions

  13. The Key Theorem • Every PPH solution can be obtained by choosing a flip for each P-Class. • Conversely, after fixing one P-Class, every distinct choice of flips of P-Classes, leads to a distinct PPH solution. • If there are k P-Classes, there are 2k – 1 distinct PPH solutions.

  14. Shadow Tree • Contains classes • Each class in the shadow tree is a subgraph of a P-Class • Merging classes results in larger classes, classes are never split • Contains tree edges and shadow edges

  15. The Algorithm • Process the genotype matrix one row at a time, starting at the first row, and modify the shadow tree • The genotype matrix only contains entries of value 0 and 2.

  16. Overview of the Algorithm for One Row • Procedure FirstPath • Procedure SecondPath • Procedure FixTree • Procedure NewEntries

  17. OldEntryList • OldEntryList : column indices that have entries of value 2 in this row and also have entries of value 2 in some previous rows 2 2 2 0 0 2 0 0 2 2 2 2 2 0 2 2 0 0 2 0 OldEntryList for row 3: 1, 2, 3, 5 3 Genotype Matrix

  18. Procedures FirstPath and SecondPath • FirstPath : Construct a first path towards the root of the shadow tree which passes through tree edges of as many columns in OldEntryList as possible • SecondPath : Construct a second path towards the root of the shadow tree which passes through tree edges of columns in OldEntryList and not on the first path

  19. Shadow Tree After Processing the First Two Rows root Genotype Matrix 1 1 2 2 2 0 0 2 0 0 2 2 2 2 2 0 2 2 0 0 2 0 1 2 2 3 4 4 2 OldEntryList for row 3 : 1, 2, 3, 5 3 5 5 3

  20. Algorithm – FirstPath root OldEntryList: 1, 2, 3, 5 1 1 CheckList: 3 , 2 Edges 4 and 5 cannot be on the same path to the root in any PPH solution 2 4 4 2 3 5 5 3

  21. Algorithm – SecondPath root OldEntryList: 1, 2, 3, 5 1 1 CheckList: 2, 3 2 4 4 2 3 5 5 3

  22. 2 Shadow Tree to PPH Solutions 1 Sites: 1 2 3 4 5 2 root a b c d 2 2 2 0 0 2 0 0 2 2 2 2 2 022 0 0 2 0 4 5 1 1 3 One PPH Solution 2 Genotype Matrix 4 4 2 3 5 5 3 Final shadow tree

  23. 2 Shadow Tree to PPH Solutions root 5 1 1 1 a,d 4 2 b,c 2 4 4 3 2 b,d a,c 3 5 5 3 Second PPH Solution Final shadow tree

  24. Implementation – Leaf Count • Leaf count of column i (L[i]): the number of 2's plus twice the number of 1's in column i. • L[i] is the number of leaves below mutation i, in every perfect phylogeny for the genotype matrix. • Along any path to the root in any PPH solution, the successive edges are labeled by columns with strictly increasing leaf counts. Leaf Count: 4 3 2 1

  25. Time Complexity • Constant number of simple operations on each edge per row • Each traversal in the shadow tree goes through O(m) edges. • The algorithm does constant number of traversals in the shadow tree for each row. • Total time: O(nm) n, m are the number of rows and columns in the genotype matrix.

  26. Results

  27. Thank you ! Paper and program can be downloaded at: http://wwwcsif.cs.ucdavis.edu/~gusfield/lpph/

More Related