Safe Haskell | None |
---|
This module contains the code that does the tree normalization and binning. It's the heart of the program.
- driver :: PhyBinConfig -> IO ()
- binthem :: [FullTree DefDecor] -> BinResults StandardDecor
- normalize :: AnnotatedTree -> AnnotatedTree
- annotateWLabLists :: NewickTree DefDecor -> AnnotatedTree
- unitTests :: Test
- acquireTreeFiles :: [String] -> IO [String]
- deAnnotate :: FullTree StandardDecor -> FullTree DefDecor
- retrieveHighlights :: (String -> String) -> LabelTable -> [FilePath] -> IO [[NewickTree ()]]
- matchAnyHighlight :: [[NewickTree ()]] -> NewickTree () -> Bool
Documentation
driver :: PhyBinConfig -> IO ()Source
Driver to put all the pieces together (parse, normalize, bin)
binthem :: [FullTree DefDecor] -> BinResults StandardDecorSource
The binning function. Takes labeled trees, classifies labels into equivalence classes.
normalize :: AnnotatedTree -> AnnotatedTreeSource
This is it, here's the routine that transforms a tree into normal form. This relies HEAVILY on lazy evaluation.
annotateWLabLists :: NewickTree DefDecor -> AnnotatedTreeSource
Add the metadata that is used for binning
acquireTreeFiles :: [String] -> IO [String]Source
Expand out directories to find all the tree files.
deAnnotate :: FullTree StandardDecor -> FullTree DefDecorSource
Take the extra annotations away. Inverse of annotateWLabLists
.
retrieveHighlights :: (String -> String) -> LabelTable -> [FilePath] -> IO [[NewickTree ()]]Source
Parse extra trees in addition to the main inputs (for --highlight).
matchAnyHighlight :: [[NewickTree ()]] -> NewickTree () -> BoolSource
Create a predicate that tests trees for consistency with the set of --highlight (consensus) trees.
Note, tree consistency is not the same as an exact match. It's like (<=) rather than (==). All trees are consistent with the star topology.