# HG changeset patch
# User earlhaminst
# Date 1510073113 18000
# Node ID 03c10736e4973b71a7d2e9504ffac449eec29e5a
# Parent a4ba317fc713271b07acda8985949d5aa6fc29ca
planemo upload for repository https://github.com/TGAC/earlham-galaxytools/tree/master/tools/ete commit 91b634b8f9b131045bbbbf43cc8edbea59ac686b-dirty
diff -r a4ba317fc713 -r 03c10736e497 ete_init_taxdb.py
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/ete_init_taxdb.py Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,24 @@
+import optparse
+
+import ete3.ncbi_taxonomy
+from six.moves.urllib.request import urlretrieve
+
+parser = optparse.OptionParser()
+parser.add_option('-t', '--taxdump', dest='taxdump', default=None,
+ help='NCBI taxdump (tar.gz) will be downloaded if not given')
+parser.add_option('-d', '--database', dest="database", default=None,
+ help='ETE sqlite data base to use (default: ~/.etetoolkit/taxa.sqlite)')
+options, args = parser.parse_args()
+if options.database is None:
+ parser.error("-d option must be specified")
+if options.taxdump is not None:
+ taxdump = options.taxdump
+else:
+ urlretrieve("http://ftp.ncbi.nih.gov/pub/taxonomy/taxdump.tar.gz", "taxdump.tar.gz")
+ taxdump = "taxdump.tar.gz"
+
+# will remove a taxdump.tar.gz file at the end
+# which will lead to an errmessage if not present
+# if the tool is run on a taxdump in the current dir it will be
+# deleted in the end
+ete3.ncbi_taxonomy.ncbiquery.update_db(dbfile=options.database, targz_file=taxdump)
diff -r a4ba317fc713 -r 03c10736e497 ete_init_taxdb.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/ete_init_taxdb.xml Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,48 @@
+
+ generates the ETE sqlite DB from the NCBI taxdump.tar.gz
+
+ ete_macros.xml
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff -r a4ba317fc713 -r 03c10736e497 ete_lineage_generator.py
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/ete_lineage_generator.py Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,128 @@
+import optparse
+import sys
+
+from ete3 import NCBITaxa
+
+# - compared to gi2taxonomy the root is excluded, since
+# the value is always "root", i.e. useless information
+# - additional levels that appear in the ncbi taxdb have
+# been added
+# (order from https://en.wikipedia.org/wiki/Taxonomic_rank#All_ranks)
+# TODO the full list of ranks could be derived from the input DB
+LONG_RANKS = [u"superkingdom", u"kingdom", u"subkingdom",
+ u"superphylum", u"phylum", u"subphylum",
+ u"superclass", u"class", u"subclass", "infraclass",
+ u"cohort",
+ u"superorder", u"order", u"suborder", u"infraorder", u"parvorder",
+ u"superfamily", u"family", u"subfamily",
+ u"tribe", u"subtribe",
+ u"genus", u"subgenus",
+ u"species group", u"species subgroup", u"species", u"subspecies",
+ u"varietas", "forma"]
+
+SHORT_RANKS = [u"kingdom",
+ u"phylum",
+ u"class",
+ u"order",
+ u"family",
+ u"genus",
+ u"species"]
+
+
+def process_taxid(ncbi, taxid, ranks, RANK_IDX, lower=False):
+ """
+ process one taxid:
+ - get lineage (as list of taxids, ranks, and names)
+ - reverse the lineage if lower ranks are to be used for filling
+ - fill the ranks with the data from the lineage
+ ncbi: ete NCBITaxa object
+ taxid: a taxid (int)
+ ranks: list of ranks (should be initialized with "NA" x number of levels of interest)
+ RANK_IDX: mapping from rank names to indices (distance to root/leaf?)
+ lower: use lower taxa for filling "NA"s
+ """
+ lineage = ncbi.get_lineage(taxid)
+ lineage_ranks = ncbi.get_rank(lineage)
+ lineage_names = ncbi.get_taxid_translator(lineage, try_synonyms=True)
+ if lower:
+ lineage.reverse()
+ for l in lineage:
+ if not lineage_ranks[l] in RANK_IDX:
+ continue
+ if ranks[RANK_IDX[lineage_ranks[l]]] != "NA":
+ continue
+ ranks[RANK_IDX[lineage_ranks[l]]] = lineage_names[l]
+
+
+# get command line options
+parser = optparse.OptionParser()
+parser.add_option('-s', '--species', dest="input_species_filename",
+ help='Species/taxid list in text format one species in each line')
+parser.add_option('-d', '--database', dest="database", default=None,
+ help='ETE sqlite data base to use (default: ~/.etetoolkit/taxa.sqlite)')
+parser.add_option('-o', '--output', dest="output", help='output file name (default: stdout)')
+parser.add_option('-f', dest="full", action="store_true", default=False,
+ help='Show all available (named) taxonomic ranks (default: only primary levels)')
+parser.add_option('-c', dest="compress", action="store_true", default=False,
+ help='Fill unnamed ranks with super/sub ranks (see -l)')
+parser.add_option('-l', dest="lower", action="store_true", default=False,
+ help='Prefer lower levels when compressed')
+parser.add_option('-r', '--rank', dest='ranks', action="append",
+ help='include rank - multiple ones can be specified')
+
+options, args = parser.parse_args()
+# check command line options
+if options.input_species_filename is None:
+ parser.error("-s option must be specified, Species list in text format one species in each line")
+if options.full and options.ranks:
+ parser.error("-f and -r can not be used at the same time")
+if options.ranks:
+ for r in options.ranks:
+ if r not in LONG_RANKS:
+ parser.error("unknown rank %s" % r)
+# setup output
+if not options.output: # if filename is not given
+ of = sys.stdout
+else:
+ of = open(options.output, "w")
+# load NCBI taxonomy DB
+ncbi = NCBITaxa(dbfile=options.database)
+# get list of ranks that are of interest
+if options.ranks:
+ RANKS = []
+ for r in LONG_RANKS:
+ if r in options.ranks:
+ RANKS.append(r)
+else:
+ if options.full:
+ RANKS = LONG_RANKS
+ else:
+ RANKS = SHORT_RANKS
+RANK_IDX = {item: index for index, item in enumerate(RANKS)}
+COMP_RANK_IDX = RANK_IDX
+if options.compress:
+ for ir in range(len(RANKS)):
+ for ilr in range(len(LONG_RANKS)):
+ if RANKS[ir] in LONG_RANKS[ilr]:
+ COMP_RANK_IDX[LONG_RANKS[ilr]] = ir
+with open(options.input_species_filename) as f:
+ for line in f.readlines():
+ line = line.strip().replace('_', ' ')
+ try:
+ taxid = int(line)
+ except ValueError:
+ # TODO: one could use fuzzy name lookup (i.e. accept typos in the species names),
+ # but then a pysqlite version that supports this is needed (needs to be enabled
+ # during compilation)
+ name2tax = ncbi.get_name_translator([line])
+ if line in name2tax:
+ taxid = name2tax[line][0]
+ else:
+ sys.stderr.write("[%s] could not be translated into a taxid!\n" % line)
+ continue
+ ranks = ["NA"] * len(RANKS)
+ process_taxid(ncbi, taxid, ranks, RANK_IDX)
+ if options.compress:
+ process_taxid(ncbi, taxid, ranks, COMP_RANK_IDX, options.lower)
+ of.write("%s\t%s\n" % (line, "\t".join(ranks)))
+of.close()
diff -r a4ba317fc713 -r 03c10736e497 ete_lineage_generator.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/ete_lineage_generator.xml Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,145 @@
+
+ from a list of species/taxids using the ETE Toolkit
+
+ ete_macros.xml
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff -r a4ba317fc713 -r 03c10736e497 ete_macros.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/ete_macros.xml Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,15 @@
+
+
+ 3.0.0b35
+
+
+ ete3
+
+
+
+
+ 10.1093/molbev/msw046
+
+
+
+
diff -r a4ba317fc713 -r 03c10736e497 ete_mod.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/ete_mod.xml Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,108 @@
+
+ manipulates tree topology by rooting, pruning or sorting branches
+
+ ete_macros.xml
+
+
+ 0.0:
+## --ultrametric $ultrametric
+## #end if
+#if $prune:
+ #set node_list = "'" + "' '".join($prune.split(',')) + "'"
+ --prune $node_list
+#end if
+$prune_preserve_lengths
+$unroot
+$sort_branches
+$ladderize
+$resolve_polytomies
+$standardize
+> '$output_tree'
+ ]]>
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff -r a4ba317fc713 -r 03c10736e497 ete_species_tree_generator.py
--- a/ete_species_tree_generator.py Fri Mar 17 16:23:39 2017 -0400
+++ b/ete_species_tree_generator.py Tue Nov 07 11:45:13 2017 -0500
@@ -1,33 +1,24 @@
import optparse
+import sys
from ete3 import NCBITaxa
-ncbi = NCBITaxa()
parser = optparse.OptionParser()
parser.add_option('-s', '--species', dest="input_species_filename",
help='Species list in text format one species in each line')
-
+parser.add_option('-d', '--database', dest="database", default=None,
+ help='ETE sqlite data base to use (default: ~/.etetoolkit/taxa.sqlite)')
+parser.add_option('-o', '--output', dest="output", help='output file name (default: stdout)')
parser.add_option('-f', '--format', type='choice', choices=['0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '100'], dest="format",
default='8', help='outpur format for tree')
-
parser.add_option('-t', '--treebest', type='choice', choices=['yes', 'no'], dest="treebest",
default='no', help='To be used in TreeBest')
-
-parser.add_option('-d', '--database', type='choice', choices=['yes', 'no'], dest="database",
- default='no', help='Update database')
-
options, args = parser.parse_args()
+if options.input_species_filename is None:
+ parser.error("-s option must be specified, Species list in text format one species in each line")
-if options.database == "yes":
- try:
- ncbi.update_taxonomy_database()
- except:
- pass
-
-if options.input_species_filename is None:
- raise Exception('-s option must be specified, Species list in text format one species in each line')
-
+ncbi = NCBITaxa(dbfile=options.database)
with open(options.input_species_filename) as f:
species_name = [_.strip().replace('_', ' ') for _ in f.readlines()]
@@ -51,6 +42,10 @@
if options.treebest == "yes":
newickTree = newickTree.rstrip(';')
newickTree = newickTree + "root;"
-
-with open('newickTree.nhx', 'w') as newickFile:
- newickFile.write(newickTree)
+# setup output
+if not options.output: # if filename is not given
+ of = sys.stdout
+else:
+ of = open(options.output, "w")
+of.write(newickTree)
+of.close()
diff -r a4ba317fc713 -r 03c10736e497 ete_species_tree_generator.xml
--- a/ete_species_tree_generator.xml Fri Mar 17 16:23:39 2017 -0400
+++ b/ete_species_tree_generator.xml Tue Nov 07 11:45:13 2017 -0500
@@ -1,27 +1,30 @@
-
+from a list of species using the ETE Toolkit
-
- ete3
-
+
+ ete_macros.xml
+
+
-
+
+
@@ -44,19 +47,21 @@
-
-
-
-
-
+
+
-
+
@@ -84,7 +89,5 @@
======= ============================================= ========================================================================================
]]>
-
- 10.1093/molbev/msw046
-
+
diff -r a4ba317fc713 -r 03c10736e497 test-data/lineage-compress-lower.txt
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/lineage-compress-lower.txt Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,62 @@
+Latimeria chalumnae Eukaryota Chordata NA Coelacanthiformes Coelacanthidae Latimeria Latimeria chalumnae
+Xenopus tropicalis Eukaryota Chordata Amphibia Batrachia Pipoidea Xenopus Xenopus tropicalis
+Ornithorhynchus anatinus Eukaryota Chordata Mammalia Monotremata Ornithorhynchidae Ornithorhynchus Ornithorhynchus anatinus
+Macropus eugenii Eukaryota Chordata Mammalia Diprotodontia Macropodidae Notamacropus Notamacropus eugenii
+Sarcophilus harrisii Eukaryota Chordata Mammalia Dasyuromorphia Dasyuridae Sarcophilus Sarcophilus harrisii
+Monodelphis domestica Eukaryota Chordata Mammalia Didelphimorphia Didelphidae Monodelphis Monodelphis domestica
+Echinops telfairi Eukaryota Chordata Mammalia Afrotheria Tenrecidae Echinops Echinops telfairi
+Procavia capensis Eukaryota Chordata Mammalia Afrotheria Procaviidae Procavia Procavia capensis
+Loxodonta africana Eukaryota Chordata Mammalia Afrotheria Elephantidae Loxodonta Loxodonta africana
+Dasypus novemcinctus Eukaryota Chordata Mammalia Xenarthra Dasypodidae Dasypus Dasypus novemcinctus
+Choloepus hoffmanni Eukaryota Chordata Mammalia Xenarthra Megalonychidae Choloepus Choloepus hoffmanni
+Ochotona princeps Eukaryota Chordata Mammalia Euarchontoglires Ochotonidae Ochotona Ochotona princeps
+Oryctolagus cuniculus Eukaryota Chordata Mammalia Euarchontoglires Leporidae Oryctolagus Oryctolagus cuniculus
+Cavia porcellus Eukaryota Chordata Mammalia Euarchontoglires Caviidae Cavia Cavia porcellus
+Ictidomys tridecemlineatus Eukaryota Chordata Mammalia Euarchontoglires Sciuridae Ictidomys Ictidomys tridecemlineatus
+Dipodomys ordii Eukaryota Chordata Mammalia Euarchontoglires Heteromyidae Dipodomys Dipodomys ordii
+Rattus norvegicus Eukaryota Chordata Mammalia Euarchontoglires Muridae Rattus Rattus norvegicus
+Mus musculus Eukaryota Chordata Mammalia Euarchontoglires Muridae Mus Mus musculus
+Tupaia belangeri Eukaryota Chordata Mammalia Euarchontoglires Tupaiidae Tupaia Tupaia belangeri
+Otolemur garnettii Eukaryota Chordata Mammalia Euarchontoglires Galagidae Otolemur Otolemur garnettii
+Microcebus murinus Eukaryota Chordata Mammalia Euarchontoglires Cheirogaleidae Microcebus Microcebus murinus
+Tarsius syrichta Eukaryota Chordata Mammalia Euarchontoglires Tarsiidae Carlito Carlito syrichta
+Callithrix jacchus Eukaryota Chordata Mammalia Euarchontoglires Cebidae Callithrix Callithrix jacchus
+Chlorocebus sabaeus Eukaryota Chordata Mammalia Euarchontoglires Cercopithecoidea Chlorocebus Chlorocebus sabaeus
+Papio anubis Eukaryota Chordata Mammalia Euarchontoglires Cercopithecoidea Papio Papio anubis
+Macaca mulatta Eukaryota Chordata Mammalia Euarchontoglires Cercopithecoidea Macaca Macaca mulatta
+Nomascus leucogenys Eukaryota Chordata Mammalia Euarchontoglires Hominoidea Nomascus Nomascus leucogenys
+Pongo abelii Eukaryota Chordata Mammalia Euarchontoglires Hominoidea Pongo Pongo abelii
+Gorilla gorilla gorilla Eukaryota Chordata Mammalia Euarchontoglires Hominoidea Gorilla Gorilla gorilla
+Pan troglodytes Eukaryota Chordata Mammalia Euarchontoglires Hominoidea Pan Pan troglodytes
+Homo sapiens Eukaryota Chordata Mammalia Euarchontoglires Hominoidea Homo Homo sapiens
+Sorex araneus Eukaryota Chordata Mammalia Laurasiatheria Soricidae Sorex Sorex araneus
+Erinaceus europaeus Eukaryota Chordata Mammalia Laurasiatheria Erinaceidae Erinaceus Erinaceus europaeus
+Pteropus vampyrus Eukaryota Chordata Mammalia Laurasiatheria Pteropodidae Pteropus Pteropus vampyrus
+Myotis lucifugus Eukaryota Chordata Mammalia Laurasiatheria Vespertilionidae Myotis Myotis lucifugus
+Felis catus Eukaryota Chordata Mammalia Laurasiatheria Felidae Felis Felis catus
+Canis lupus familiaris Eukaryota Chordata Mammalia Laurasiatheria Canidae Canis Canis lupus
+Mustela putorius furo Eukaryota Chordata Mammalia Laurasiatheria Mustelidae Mustela Mustela putorius
+Ailuropoda melanoleuca Eukaryota Chordata Mammalia Laurasiatheria Ursidae Ailuropoda Ailuropoda melanoleuca
+Equus caballus Eukaryota Chordata Mammalia Laurasiatheria Equidae Equus Equus caballus
+Vicugna pacos Eukaryota Chordata Mammalia Laurasiatheria Camelidae Vicugna Vicugna pacos
+Sus scrofa Eukaryota Chordata Mammalia Laurasiatheria Suidae Sus Sus scrofa
+Tursiops truncatus Eukaryota Chordata Mammalia Laurasiatheria Delphinidae Tursiops Tursiops truncatus
+Ovis aries Eukaryota Chordata Mammalia Laurasiatheria Bovidae Ovis Ovis aries
+Bos taurus Eukaryota Chordata Mammalia Laurasiatheria Bovidae Bos Bos taurus
+Anolis carolinensis Eukaryota Chordata NA Lepidosauria Dactyloidae Anolis Anolis carolinensis
+Pelodiscus sinensis Eukaryota Chordata NA Testudines Trionychidae Pelodiscus Pelodiscus sinensis
+Taeniopygia guttata Eukaryota Chordata Aves Neognathae Passeroidea Taeniopygia Taeniopygia guttata
+Ficedula albicollis Eukaryota Chordata Aves Neognathae Muscicapidae Ficedula Ficedula albicollis
+Anas platyrhynchos Eukaryota Chordata Aves Neognathae Anatidae Anas Anas platyrhynchos
+Meleagris gallopavo Eukaryota Chordata Aves Neognathae Phasianidae Meleagris Meleagris gallopavo
+Gallus gallus Eukaryota Chordata Aves Neognathae Phasianidae Gallus Gallus gallus
+Lepisosteus oculatus Eukaryota Chordata Actinopterygii Semionotiformes Lepisosteidae Lepisosteus Lepisosteus oculatus
+Danio rerio Eukaryota Chordata Actinopterygii Cypriniphysae Cyprinoidea Danio Danio rerio
+Astyanax mexicanus Eukaryota Chordata Actinopterygii Characiphysae Characidae Astyanax Astyanax mexicanus
+Gadus morhua Eukaryota Chordata Actinopterygii Gadiformes Gadidae Gadus Gadus morhua
+Oreochromis niloticus Eukaryota Chordata Actinopterygii Cichlomorphae Cichlidae Oreochromis Oreochromis niloticus
+Poecilia formosa Eukaryota Chordata Actinopterygii Atherinomorphae Poeciliidae Poecilia Poecilia formosa
+Xiphophorus maculatus Eukaryota Chordata Actinopterygii Atherinomorphae Poeciliidae Xiphophorus Xiphophorus maculatus
+Gasterosteus aculeatus Eukaryota Chordata Actinopterygii Perciformes Gasterosteidae Gasterosteus Gasterosteus aculeatus
+Tetraodon nigroviridis Eukaryota Chordata Actinopterygii Tetraodontiformes Tetradontoidea Tetraodon Tetraodon nigroviridis
+Takifugu rubripes Eukaryota Chordata Actinopterygii Tetraodontiformes Tetradontoidea Takifugu Takifugu rubripes
diff -r a4ba317fc713 -r 03c10736e497 test-data/lineage-compress.txt
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/lineage-compress.txt Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,62 @@
+Latimeria chalumnae Eukaryota Chordata NA Coelacanthiformes Coelacanthidae Latimeria Latimeria chalumnae
+Xenopus tropicalis Eukaryota Chordata Amphibia Batrachia Pipoidea Xenopus Xenopus tropicalis
+Ornithorhynchus anatinus Eukaryota Chordata Mammalia Monotremata Ornithorhynchidae Ornithorhynchus Ornithorhynchus anatinus
+Macropus eugenii Eukaryota Chordata Mammalia Diprotodontia Macropodidae Notamacropus Notamacropus eugenii
+Sarcophilus harrisii Eukaryota Chordata Mammalia Dasyuromorphia Dasyuridae Sarcophilus Sarcophilus harrisii
+Monodelphis domestica Eukaryota Chordata Mammalia Didelphimorphia Didelphidae Monodelphis Monodelphis domestica
+Echinops telfairi Eukaryota Chordata Mammalia Afrotheria Tenrecidae Echinops Echinops telfairi
+Procavia capensis Eukaryota Chordata Mammalia Afrotheria Procaviidae Procavia Procavia capensis
+Loxodonta africana Eukaryota Chordata Mammalia Afrotheria Elephantidae Loxodonta Loxodonta africana
+Dasypus novemcinctus Eukaryota Chordata Mammalia Xenarthra Dasypodidae Dasypus Dasypus novemcinctus
+Choloepus hoffmanni Eukaryota Chordata Mammalia Xenarthra Megalonychidae Choloepus Choloepus hoffmanni
+Ochotona princeps Eukaryota Chordata Mammalia Euarchontoglires Ochotonidae Ochotona Ochotona princeps
+Oryctolagus cuniculus Eukaryota Chordata Mammalia Euarchontoglires Leporidae Oryctolagus Oryctolagus cuniculus
+Cavia porcellus Eukaryota Chordata Mammalia Euarchontoglires Caviidae Cavia Cavia porcellus
+Ictidomys tridecemlineatus Eukaryota Chordata Mammalia Euarchontoglires Sciuridae Ictidomys Ictidomys tridecemlineatus
+Dipodomys ordii Eukaryota Chordata Mammalia Euarchontoglires Heteromyidae Dipodomys Dipodomys ordii
+Rattus norvegicus Eukaryota Chordata Mammalia Euarchontoglires Muridae Rattus Rattus norvegicus
+Mus musculus Eukaryota Chordata Mammalia Euarchontoglires Muridae Mus Mus musculus
+Tupaia belangeri Eukaryota Chordata Mammalia Euarchontoglires Tupaiidae Tupaia Tupaia belangeri
+Otolemur garnettii Eukaryota Chordata Mammalia Euarchontoglires Galagidae Otolemur Otolemur garnettii
+Microcebus murinus Eukaryota Chordata Mammalia Euarchontoglires Cheirogaleidae Microcebus Microcebus murinus
+Tarsius syrichta Eukaryota Chordata Mammalia Euarchontoglires Tarsiidae Carlito Carlito syrichta
+Callithrix jacchus Eukaryota Chordata Mammalia Euarchontoglires Cebidae Callithrix Callithrix jacchus
+Chlorocebus sabaeus Eukaryota Chordata Mammalia Euarchontoglires Cercopithecoidea Chlorocebus Chlorocebus sabaeus
+Papio anubis Eukaryota Chordata Mammalia Euarchontoglires Cercopithecoidea Papio Papio anubis
+Macaca mulatta Eukaryota Chordata Mammalia Euarchontoglires Cercopithecoidea Macaca Macaca mulatta
+Nomascus leucogenys Eukaryota Chordata Mammalia Euarchontoglires Hominoidea Nomascus Nomascus leucogenys
+Pongo abelii Eukaryota Chordata Mammalia Euarchontoglires Hominoidea Pongo Pongo abelii
+Gorilla gorilla gorilla Eukaryota Chordata Mammalia Euarchontoglires Hominoidea Gorilla Gorilla gorilla
+Pan troglodytes Eukaryota Chordata Mammalia Euarchontoglires Hominoidea Pan Pan troglodytes
+Homo sapiens Eukaryota Chordata Mammalia Euarchontoglires Hominoidea Homo Homo sapiens
+Sorex araneus Eukaryota Chordata Mammalia Laurasiatheria Soricidae Sorex Sorex araneus
+Erinaceus europaeus Eukaryota Chordata Mammalia Laurasiatheria Erinaceidae Erinaceus Erinaceus europaeus
+Pteropus vampyrus Eukaryota Chordata Mammalia Laurasiatheria Pteropodidae Pteropus Pteropus vampyrus
+Myotis lucifugus Eukaryota Chordata Mammalia Laurasiatheria Vespertilionidae Myotis Myotis lucifugus
+Felis catus Eukaryota Chordata Mammalia Laurasiatheria Felidae Felis Felis catus
+Canis lupus familiaris Eukaryota Chordata Mammalia Laurasiatheria Canidae Canis Canis lupus
+Mustela putorius furo Eukaryota Chordata Mammalia Laurasiatheria Mustelidae Mustela Mustela putorius
+Ailuropoda melanoleuca Eukaryota Chordata Mammalia Laurasiatheria Ursidae Ailuropoda Ailuropoda melanoleuca
+Equus caballus Eukaryota Chordata Mammalia Laurasiatheria Equidae Equus Equus caballus
+Vicugna pacos Eukaryota Chordata Mammalia Laurasiatheria Camelidae Vicugna Vicugna pacos
+Sus scrofa Eukaryota Chordata Mammalia Laurasiatheria Suidae Sus Sus scrofa
+Tursiops truncatus Eukaryota Chordata Mammalia Laurasiatheria Delphinidae Tursiops Tursiops truncatus
+Ovis aries Eukaryota Chordata Mammalia Laurasiatheria Bovidae Ovis Ovis aries
+Bos taurus Eukaryota Chordata Mammalia Laurasiatheria Bovidae Bos Bos taurus
+Anolis carolinensis Eukaryota Chordata NA Lepidosauria Dactyloidae Anolis Anolis carolinensis
+Pelodiscus sinensis Eukaryota Chordata NA Testudines Trionychidae Pelodiscus Pelodiscus sinensis
+Taeniopygia guttata Eukaryota Chordata Aves Neognathae Passeroidea Taeniopygia Taeniopygia guttata
+Ficedula albicollis Eukaryota Chordata Aves Neognathae Muscicapidae Ficedula Ficedula albicollis
+Anas platyrhynchos Eukaryota Chordata Aves Neognathae Anatidae Anas Anas platyrhynchos
+Meleagris gallopavo Eukaryota Chordata Aves Neognathae Phasianidae Meleagris Meleagris gallopavo
+Gallus gallus Eukaryota Chordata Aves Neognathae Phasianidae Gallus Gallus gallus
+Lepisosteus oculatus Eukaryota Chordata Actinopterygii Semionotiformes Lepisosteidae Lepisosteus Lepisosteus oculatus
+Danio rerio Eukaryota Chordata Actinopterygii Cypriniphysae Cyprinoidea Danio Danio rerio
+Astyanax mexicanus Eukaryota Chordata Actinopterygii Characiphysae Characidae Astyanax Astyanax mexicanus
+Gadus morhua Eukaryota Chordata Actinopterygii Gadiformes Gadidae Gadus Gadus morhua
+Oreochromis niloticus Eukaryota Chordata Actinopterygii Cichlomorphae Cichlidae Oreochromis Oreochromis niloticus
+Poecilia formosa Eukaryota Chordata Actinopterygii Atherinomorphae Poeciliidae Poecilia Poecilia formosa
+Xiphophorus maculatus Eukaryota Chordata Actinopterygii Atherinomorphae Poeciliidae Xiphophorus Xiphophorus maculatus
+Gasterosteus aculeatus Eukaryota Chordata Actinopterygii Perciformes Gasterosteidae Gasterosteus Gasterosteus aculeatus
+Tetraodon nigroviridis Eukaryota Chordata Actinopterygii Tetraodontiformes Tetradontoidea Tetraodon Tetraodon nigroviridis
+Takifugu rubripes Eukaryota Chordata Actinopterygii Tetraodontiformes Tetradontoidea Takifugu Takifugu rubripes
diff -r a4ba317fc713 -r 03c10736e497 test-data/lineage-full.txt
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/lineage-full.txt Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,62 @@
+Latimeria chalumnae Eukaryota Metazoa NA NA Chordata Craniata NA NA NA NA NA NA Coelacanthiformes NA NA NA NA Coelacanthidae NA NA NA Latimeria NA NA NA Latimeria chalumnae NA NA NA
+Xenopus tropicalis Eukaryota Metazoa NA NA Chordata Craniata NA Amphibia NA NA NA Batrachia Anura NA NA NA Pipoidea Pipidae Xenopodinae NA NA Xenopus Silurana NA NA Xenopus tropicalis NA NA NA
+Ornithorhynchus anatinus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA NA Monotremata NA NA NA NA Ornithorhynchidae NA NA NA Ornithorhynchus NA NA NA Ornithorhynchus anatinus NA NA NA
+Macropus eugenii Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA NA Diprotodontia NA NA NA NA Macropodidae NA NA NA Notamacropus NA NA NA Notamacropus eugenii NA NA NA
+Sarcophilus harrisii Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA NA Dasyuromorphia NA NA NA NA Dasyuridae NA NA NA Sarcophilus NA NA NA Sarcophilus harrisii NA NA NA
+Monodelphis domestica Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA NA Didelphimorphia NA NA NA NA Didelphidae Didelphinae NA NA Monodelphis NA NA NA Monodelphis domestica NA NA NA
+Echinops telfairi Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Afrotheria NA NA NA NA NA Tenrecidae Tenrecinae NA NA Echinops NA NA NA Echinops telfairi NA NA NA
+Procavia capensis Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Afrotheria Hyracoidea NA NA NA NA Procaviidae NA NA NA Procavia NA NA NA Procavia capensis NA NA NA
+Loxodonta africana Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Afrotheria Proboscidea NA NA NA NA Elephantidae NA NA NA Loxodonta NA NA NA Loxodonta africana NA NA NA
+Dasypus novemcinctus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Xenarthra Cingulata NA NA NA NA Dasypodidae NA NA NA Dasypus NA NA NA Dasypus novemcinctus NA NA NA
+Choloepus hoffmanni Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Xenarthra Pilosa Folivora NA NA NA Megalonychidae NA NA NA Choloepus NA NA NA Choloepus hoffmanni NA NA NA
+Ochotona princeps Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Lagomorpha NA NA NA NA Ochotonidae NA NA NA Ochotona NA NA NA Ochotona princeps NA NA NA
+Oryctolagus cuniculus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Lagomorpha NA NA NA NA Leporidae NA NA NA Oryctolagus NA NA NA Oryctolagus cuniculus NA NA NA
+Cavia porcellus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Rodentia Hystricomorpha NA NA NA Caviidae NA NA NA Cavia NA NA NA Cavia porcellus NA NA NA
+Ictidomys tridecemlineatus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Rodentia Sciuromorpha NA NA NA Sciuridae Xerinae Marmotini NA Ictidomys NA NA NA Ictidomys tridecemlineatus NA NA NA
+Dipodomys ordii Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Rodentia Castorimorpha NA NA NA Heteromyidae Dipodomyinae NA NA Dipodomys NA NA NA Dipodomys ordii NA NA NA
+Rattus norvegicus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Rodentia Myomorpha NA NA NA Muridae Murinae NA NA Rattus NA NA NA Rattus norvegicus NA NA NA
+Mus musculus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Rodentia Myomorpha NA NA NA Muridae Murinae NA NA Mus Mus NA NA Mus musculus NA NA NA
+Tupaia belangeri Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Scandentia NA NA NA NA Tupaiidae NA NA NA Tupaia NA NA NA Tupaia belangeri NA NA NA
+Otolemur garnettii Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Primates Strepsirrhini Lorisiformes NA NA Galagidae NA NA NA Otolemur NA NA NA Otolemur garnettii NA NA NA
+Microcebus murinus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Primates Strepsirrhini Lemuriformes NA NA Cheirogaleidae NA NA NA Microcebus NA NA NA Microcebus murinus NA NA NA
+Tarsius syrichta Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Primates Haplorrhini Tarsiiformes NA NA Tarsiidae NA NA NA Carlito NA NA NA Carlito syrichta NA NA NA
+Callithrix jacchus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Primates Haplorrhini Simiiformes Platyrrhini NA Cebidae Callitrichinae NA NA Callithrix Callithrix NA NA Callithrix jacchus NA NA NA
+Chlorocebus sabaeus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Primates Haplorrhini Simiiformes Catarrhini Cercopithecoidea Cercopithecidae Cercopithecinae NA NA Chlorocebus NA NA NA Chlorocebus sabaeus NA NA NA
+Papio anubis Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Primates Haplorrhini Simiiformes Catarrhini Cercopithecoidea Cercopithecidae Cercopithecinae NA NA Papio NA NA NA Papio anubis NA NA NA
+Macaca mulatta Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Primates Haplorrhini Simiiformes Catarrhini Cercopithecoidea Cercopithecidae Cercopithecinae NA NA Macaca NA NA NA Macaca mulatta NA NA NA
+Nomascus leucogenys Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Primates Haplorrhini Simiiformes Catarrhini Hominoidea Hylobatidae NA NA NA Nomascus NA NA NA Nomascus leucogenys NA NA NA
+Pongo abelii Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Primates Haplorrhini Simiiformes Catarrhini Hominoidea Hominidae Ponginae NA NA Pongo NA NA NA Pongo abelii NA NA NA
+Gorilla gorilla gorilla Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Primates Haplorrhini Simiiformes Catarrhini Hominoidea Hominidae Homininae NA NA Gorilla NA NA NA Gorilla gorilla Gorilla gorilla gorilla NA NA
+Pan troglodytes Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Primates Haplorrhini Simiiformes Catarrhini Hominoidea Hominidae Homininae NA NA Pan NA NA NA Pan troglodytes NA NA NA
+Homo sapiens Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Euarchontoglires Primates Haplorrhini Simiiformes Catarrhini Hominoidea Hominidae Homininae NA NA Homo NA NA NA Homo sapiens NA NA NA
+Sorex araneus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria Insectivora NA NA NA NA Soricidae Soricinae NA NA Sorex NA NA NA Sorex araneus NA NA NA
+Erinaceus europaeus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria Insectivora NA NA NA NA Erinaceidae Erinaceinae NA NA Erinaceus NA NA NA Erinaceus europaeus NA NA NA
+Pteropus vampyrus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria Chiroptera Megachiroptera NA NA NA Pteropodidae Pteropodinae NA NA Pteropus NA NA NA Pteropus vampyrus NA NA NA
+Myotis lucifugus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria Chiroptera Microchiroptera NA NA NA Vespertilionidae NA NA NA Myotis NA NA NA Myotis lucifugus NA NA NA
+Felis catus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria Carnivora Feliformia NA NA NA Felidae Felinae NA NA Felis NA NA NA Felis catus NA NA NA
+Canis lupus familiaris Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria Carnivora Caniformia NA NA NA Canidae NA NA NA Canis NA NA NA Canis lupus Canis lupus familiaris NA NA
+Mustela putorius furo Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria Carnivora Caniformia NA NA NA Mustelidae Mustelinae NA NA Mustela NA NA NA Mustela putorius Mustela putorius furo NA NA
+Ailuropoda melanoleuca Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria Carnivora Caniformia NA NA NA Ursidae NA NA NA Ailuropoda NA NA NA Ailuropoda melanoleuca NA NA NA
+Equus caballus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria Perissodactyla NA NA NA NA Equidae NA NA NA Equus Equus NA NA Equus caballus NA NA NA
+Vicugna pacos Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria NA Tylopoda NA NA NA Camelidae NA NA NA Vicugna NA NA NA Vicugna pacos NA NA NA
+Sus scrofa Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria NA NA Suina NA NA Suidae NA NA NA Sus NA NA NA Sus scrofa NA NA NA
+Tursiops truncatus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria Cetacea Odontoceti NA NA NA Delphinidae NA NA NA Tursiops NA NA NA Tursiops truncatus NA NA NA
+Ovis aries Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria NA Ruminantia Pecora NA NA Bovidae Caprinae NA NA Ovis NA NA NA Ovis aries NA NA NA
+Bos taurus Eukaryota Metazoa NA NA Chordata Craniata NA Mammalia NA NA NA Laurasiatheria NA Ruminantia Pecora NA NA Bovidae Bovinae NA NA Bos NA NA NA Bos taurus NA NA NA
+Anolis carolinensis Eukaryota Metazoa NA NA Chordata Craniata NA NA NA NA NA Lepidosauria Squamata Iguania NA NA NA Dactyloidae NA NA NA Anolis NA NA NA Anolis carolinensis NA NA NA
+Pelodiscus sinensis Eukaryota Metazoa NA NA Chordata Craniata NA NA NA NA NA NA Testudines Cryptodira NA NA NA Trionychidae NA NA NA Pelodiscus NA NA NA Pelodiscus sinensis NA NA NA
+Taeniopygia guttata Eukaryota Metazoa NA NA Chordata Craniata NA Aves NA NA NA Neognathae Passeriformes NA NA NA Passeroidea Estrildidae Estrildinae NA NA Taeniopygia NA NA NA Taeniopygia guttata NA NA NA
+Ficedula albicollis Eukaryota Metazoa NA NA Chordata Craniata NA Aves NA NA NA Neognathae Passeriformes NA NA NA NA Muscicapidae NA NA NA Ficedula NA NA NA Ficedula albicollis NA NA NA
+Anas platyrhynchos Eukaryota Metazoa NA NA Chordata Craniata NA Aves NA NA NA Neognathae Anseriformes NA NA NA NA Anatidae NA NA NA Anas NA NA NA Anas platyrhynchos NA NA NA
+Meleagris gallopavo Eukaryota Metazoa NA NA Chordata Craniata NA Aves NA NA NA Neognathae Galliformes NA NA NA NA Phasianidae Meleagridinae NA NA Meleagris NA NA NA Meleagris gallopavo NA NA NA
+Gallus gallus Eukaryota Metazoa NA NA Chordata Craniata NA Aves NA NA NA Neognathae Galliformes NA NA NA NA Phasianidae Phasianinae NA NA Gallus NA NA NA Gallus gallus NA NA NA
+Lepisosteus oculatus Eukaryota Metazoa NA NA Chordata Craniata Actinopterygii Actinopteri Neopterygii Holostei NA NA Semionotiformes NA NA NA NA Lepisosteidae NA NA NA Lepisosteus NA NA NA Lepisosteus oculatus NA NA NA
+Danio rerio Eukaryota Metazoa NA NA Chordata Craniata Actinopterygii Actinopteri Neopterygii Teleostei NA Cypriniphysae Cypriniformes NA NA NA Cyprinoidea Cyprinidae NA NA NA Danio NA NA NA Danio rerio NA NA NA
+Astyanax mexicanus Eukaryota Metazoa NA NA Chordata Craniata Actinopterygii Actinopteri Neopterygii Teleostei NA Characiphysae Characiformes Characoidei NA NA NA Characidae NA NA NA Astyanax NA NA NA Astyanax mexicanus NA NA NA
+Gadus morhua Eukaryota Metazoa NA NA Chordata Craniata Actinopterygii Actinopteri Neopterygii Teleostei NA NA Gadiformes Gadoidei NA NA NA Gadidae NA NA NA Gadus NA NA NA Gadus morhua NA NA NA
+Oreochromis niloticus Eukaryota Metazoa NA NA Chordata Craniata Actinopterygii Actinopteri Neopterygii Teleostei NA Cichlomorphae Cichliformes NA NA NA NA Cichlidae Pseudocrenilabrinae Oreochromini NA Oreochromis NA NA NA Oreochromis niloticus NA NA NA
+Poecilia formosa Eukaryota Metazoa NA NA Chordata Craniata Actinopterygii Actinopteri Neopterygii Teleostei NA Atherinomorphae Cyprinodontiformes Cyprinodontoidei NA NA NA Poeciliidae Poeciliinae NA NA Poecilia NA NA NA Poecilia formosa NA NA NA
+Xiphophorus maculatus Eukaryota Metazoa NA NA Chordata Craniata Actinopterygii Actinopteri Neopterygii Teleostei NA Atherinomorphae Cyprinodontiformes Cyprinodontoidei NA NA NA Poeciliidae Poeciliinae NA NA Xiphophorus NA NA NA Xiphophorus maculatus NA NA NA
+Gasterosteus aculeatus Eukaryota Metazoa NA NA Chordata Craniata Actinopterygii Actinopteri Neopterygii Teleostei NA NA Perciformes Cottioidei Gasterosteales NA NA Gasterosteidae NA NA NA Gasterosteus NA NA NA Gasterosteus aculeatus NA NA NA
+Tetraodon nigroviridis Eukaryota Metazoa NA NA Chordata Craniata Actinopterygii Actinopteri Neopterygii Teleostei NA NA Tetraodontiformes Tetraodontoidei NA NA Tetradontoidea Tetraodontidae NA NA NA Tetraodon NA NA NA Tetraodon nigroviridis NA NA NA
+Takifugu rubripes Eukaryota Metazoa NA NA Chordata Craniata Actinopterygii Actinopteri Neopterygii Teleostei NA NA Tetraodontiformes Tetraodontoidei NA NA Tetradontoidea Tetraodontidae NA NA NA Takifugu NA NA NA Takifugu rubripes NA NA NA
diff -r a4ba317fc713 -r 03c10736e497 test-data/lineage.txt
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/lineage.txt Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,62 @@
+Latimeria chalumnae Metazoa Chordata NA Coelacanthiformes Coelacanthidae Latimeria Latimeria chalumnae
+Xenopus tropicalis Metazoa Chordata Amphibia Anura Pipidae Xenopus Xenopus tropicalis
+Ornithorhynchus anatinus Metazoa Chordata Mammalia Monotremata Ornithorhynchidae Ornithorhynchus Ornithorhynchus anatinus
+Macropus eugenii Metazoa Chordata Mammalia Diprotodontia Macropodidae Notamacropus Notamacropus eugenii
+Sarcophilus harrisii Metazoa Chordata Mammalia Dasyuromorphia Dasyuridae Sarcophilus Sarcophilus harrisii
+Monodelphis domestica Metazoa Chordata Mammalia Didelphimorphia Didelphidae Monodelphis Monodelphis domestica
+Echinops telfairi Metazoa Chordata Mammalia NA Tenrecidae Echinops Echinops telfairi
+Procavia capensis Metazoa Chordata Mammalia Hyracoidea Procaviidae Procavia Procavia capensis
+Loxodonta africana Metazoa Chordata Mammalia Proboscidea Elephantidae Loxodonta Loxodonta africana
+Dasypus novemcinctus Metazoa Chordata Mammalia Cingulata Dasypodidae Dasypus Dasypus novemcinctus
+Choloepus hoffmanni Metazoa Chordata Mammalia Pilosa Megalonychidae Choloepus Choloepus hoffmanni
+Ochotona princeps Metazoa Chordata Mammalia Lagomorpha Ochotonidae Ochotona Ochotona princeps
+Oryctolagus cuniculus Metazoa Chordata Mammalia Lagomorpha Leporidae Oryctolagus Oryctolagus cuniculus
+Cavia porcellus Metazoa Chordata Mammalia Rodentia Caviidae Cavia Cavia porcellus
+Ictidomys tridecemlineatus Metazoa Chordata Mammalia Rodentia Sciuridae Ictidomys Ictidomys tridecemlineatus
+Dipodomys ordii Metazoa Chordata Mammalia Rodentia Heteromyidae Dipodomys Dipodomys ordii
+Rattus norvegicus Metazoa Chordata Mammalia Rodentia Muridae Rattus Rattus norvegicus
+Mus musculus Metazoa Chordata Mammalia Rodentia Muridae Mus Mus musculus
+Tupaia belangeri Metazoa Chordata Mammalia Scandentia Tupaiidae Tupaia Tupaia belangeri
+Otolemur garnettii Metazoa Chordata Mammalia Primates Galagidae Otolemur Otolemur garnettii
+Microcebus murinus Metazoa Chordata Mammalia Primates Cheirogaleidae Microcebus Microcebus murinus
+Tarsius syrichta Metazoa Chordata Mammalia Primates Tarsiidae Carlito Carlito syrichta
+Callithrix jacchus Metazoa Chordata Mammalia Primates Cebidae Callithrix Callithrix jacchus
+Chlorocebus sabaeus Metazoa Chordata Mammalia Primates Cercopithecidae Chlorocebus Chlorocebus sabaeus
+Papio anubis Metazoa Chordata Mammalia Primates Cercopithecidae Papio Papio anubis
+Macaca mulatta Metazoa Chordata Mammalia Primates Cercopithecidae Macaca Macaca mulatta
+Nomascus leucogenys Metazoa Chordata Mammalia Primates Hylobatidae Nomascus Nomascus leucogenys
+Pongo abelii Metazoa Chordata Mammalia Primates Hominidae Pongo Pongo abelii
+Gorilla gorilla gorilla Metazoa Chordata Mammalia Primates Hominidae Gorilla Gorilla gorilla
+Pan troglodytes Metazoa Chordata Mammalia Primates Hominidae Pan Pan troglodytes
+Homo sapiens Metazoa Chordata Mammalia Primates Hominidae Homo Homo sapiens
+Sorex araneus Metazoa Chordata Mammalia Insectivora Soricidae Sorex Sorex araneus
+Erinaceus europaeus Metazoa Chordata Mammalia Insectivora Erinaceidae Erinaceus Erinaceus europaeus
+Pteropus vampyrus Metazoa Chordata Mammalia Chiroptera Pteropodidae Pteropus Pteropus vampyrus
+Myotis lucifugus Metazoa Chordata Mammalia Chiroptera Vespertilionidae Myotis Myotis lucifugus
+Felis catus Metazoa Chordata Mammalia Carnivora Felidae Felis Felis catus
+Canis lupus familiaris Metazoa Chordata Mammalia Carnivora Canidae Canis Canis lupus
+Mustela putorius furo Metazoa Chordata Mammalia Carnivora Mustelidae Mustela Mustela putorius
+Ailuropoda melanoleuca Metazoa Chordata Mammalia Carnivora Ursidae Ailuropoda Ailuropoda melanoleuca
+Equus caballus Metazoa Chordata Mammalia Perissodactyla Equidae Equus Equus caballus
+Vicugna pacos Metazoa Chordata Mammalia NA Camelidae Vicugna Vicugna pacos
+Sus scrofa Metazoa Chordata Mammalia NA Suidae Sus Sus scrofa
+Tursiops truncatus Metazoa Chordata Mammalia Cetacea Delphinidae Tursiops Tursiops truncatus
+Ovis aries Metazoa Chordata Mammalia NA Bovidae Ovis Ovis aries
+Bos taurus Metazoa Chordata Mammalia NA Bovidae Bos Bos taurus
+Anolis carolinensis Metazoa Chordata NA Squamata Dactyloidae Anolis Anolis carolinensis
+Pelodiscus sinensis Metazoa Chordata NA Testudines Trionychidae Pelodiscus Pelodiscus sinensis
+Taeniopygia guttata Metazoa Chordata Aves Passeriformes Estrildidae Taeniopygia Taeniopygia guttata
+Ficedula albicollis Metazoa Chordata Aves Passeriformes Muscicapidae Ficedula Ficedula albicollis
+Anas platyrhynchos Metazoa Chordata Aves Anseriformes Anatidae Anas Anas platyrhynchos
+Meleagris gallopavo Metazoa Chordata Aves Galliformes Phasianidae Meleagris Meleagris gallopavo
+Gallus gallus Metazoa Chordata Aves Galliformes Phasianidae Gallus Gallus gallus
+Lepisosteus oculatus Metazoa Chordata Actinopteri Semionotiformes Lepisosteidae Lepisosteus Lepisosteus oculatus
+Danio rerio Metazoa Chordata Actinopteri Cypriniformes Cyprinidae Danio Danio rerio
+Astyanax mexicanus Metazoa Chordata Actinopteri Characiformes Characidae Astyanax Astyanax mexicanus
+Gadus morhua Metazoa Chordata Actinopteri Gadiformes Gadidae Gadus Gadus morhua
+Oreochromis niloticus Metazoa Chordata Actinopteri Cichliformes Cichlidae Oreochromis Oreochromis niloticus
+Poecilia formosa Metazoa Chordata Actinopteri Cyprinodontiformes Poeciliidae Poecilia Poecilia formosa
+Xiphophorus maculatus Metazoa Chordata Actinopteri Cyprinodontiformes Poeciliidae Xiphophorus Xiphophorus maculatus
+Gasterosteus aculeatus Metazoa Chordata Actinopteri Perciformes Gasterosteidae Gasterosteus Gasterosteus aculeatus
+Tetraodon nigroviridis Metazoa Chordata Actinopteri Tetraodontiformes Tetraodontidae Tetraodon Tetraodon nigroviridis
+Takifugu rubripes Metazoa Chordata Actinopteri Tetraodontiformes Tetraodontidae Takifugu Takifugu rubripes
diff -r a4ba317fc713 -r 03c10736e497 test-data/out.nhx
--- a/test-data/out.nhx Fri Mar 17 16:23:39 2017 -0400
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,1 +0,0 @@
-((((((((((((((((Homosapiens*,Pantroglodytes*,Gorillagorillagorilla*)207598,Pongoabelii*)9604,Nomascusleucogenys*)314295,(Chlorocebussabaeus*,Macacamulatta*,Papioanubis*)9528)9526,Callithrixjacchus*)314293,Tarsiussyrichta*)376913,(Microcebusmurinus*,Otolemurgarnettii*)376911)9443,((Oryctolaguscuniculus*,Ochotonaprinceps*)9975,(((Rattusnorvegicus*,Musmusculus*)39107,Dipodomysordii*,Ictidomystridecemlineatus*)33553,Caviaporcellus*)9989)314147,Tupaiabelangeri*)314146,(((Ailuropodamelanoleuca*,Canislupusfamiliaris*,Mustelaputoriusfuro*)379584,Feliscatus*)33554,(Erinaceuseuropaeus*,Sorexaraneus*)9362,(Myotislucifugus*,Pteropusvampyrus*)9397,((Ovisaries*,Bostaurus*)9895,Vicugnapacos*,Susscrofa*,Tursiopstruncatus*)91561,Equuscaballus*)314145)1437010,(Dasypusnovemcinctus*,Choloepushoffmanni*)9348,(Echinopstelfairi*,Loxodontaafricana*,Procaviacapensis*)311790)9347,(Sarcophilusharrisii*,Macropuseugenii*,Monodelphisdomestica*)9263)32525,Ornithorhynchusanatinus*)40674,((Pelodiscussinensis*,(((Meleagrisgallopavo*,Gallusgallus*)9005,Anasplatyrhynchos*)1549675,(Ficedulaalbicollis*,Taeniopygiaguttata*)9126)8825)1329799,Anoliscarolinensis*)32561)32524,Xenopustropicalis*)32523,Latimeriachalumnae*)8287,(((Daniorerio*,Astyanaxmexicanus*)186626,((((Tetraodonnigroviridis*,Takifugurubripes*)31031,Gasterosteusaculeatus*)1489922,((Poeciliaformosa*,Xiphophorusmaculatus*)586240,Oreochromisniloticus*)1489908)1489872,Gadusmorhua*)123368)186625,Lepisosteusoculatus*)41665)root;
\ No newline at end of file
diff -r a4ba317fc713 -r 03c10736e497 test-data/taxdump.sqlite
Binary file test-data/taxdump.sqlite has changed
diff -r a4ba317fc713 -r 03c10736e497 test-data/taxdump.tar.gz
Binary file test-data/taxdump.tar.gz has changed
diff -r a4ba317fc713 -r 03c10736e497 test-data/tree1.nhx
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/tree1.nhx Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,2 @@
+((A,B),C);
+
diff -r a4ba317fc713 -r 03c10736e497 test-data/tree1_ladder.nhx
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/tree1_ladder.nhx Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,1 @@
+(C:2,(A:1,B:1)1:1);
diff -r a4ba317fc713 -r 03c10736e497 test-data/tree1_ogA.nhx
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/tree1_ogA.nhx Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,1 @@
+(A:2.5,(B:1.25,C:1.25)1:1.25);
diff -r a4ba317fc713 -r 03c10736e497 test-data/tree1_pruneAC.nhx
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/tree1_pruneAC.nhx Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,1 @@
+(C:1,A:1);
diff -r a4ba317fc713 -r 03c10736e497 test-data/tree1_pruneACpreserve.nhx
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/tree1_pruneACpreserve.nhx Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,1 @@
+(C:2,A:2);
diff -r a4ba317fc713 -r 03c10736e497 test-data/tree1_unroot.nhx
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/tree1_unroot.nhx Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,1 @@
+(C:1,A:1,B:1);
diff -r a4ba317fc713 -r 03c10736e497 test-data/tree1_unroot_resolve.nhx
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/tree1_unroot_resolve.nhx Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,1 @@
+((A:0.5,B:0.5)0:0.5,C:1);
diff -r a4ba317fc713 -r 03c10736e497 test-data/tree2.nhx
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/tree2.nhx Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,2 @@
+((C,A),B);
+
diff -r a4ba317fc713 -r 03c10736e497 test-data/tree2_sort.nhx
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/tree2_sort.nhx Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,1 @@
+((A:1,C:1)1:1,B:2);
diff -r a4ba317fc713 -r 03c10736e497 test-data/tree3.nhx
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/tree3.nhx Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,1 @@
+(C:1,(A:1):1,B:1);
diff -r a4ba317fc713 -r 03c10736e497 test-data/tree3_stand.nhx
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/tree3_stand.nhx Tue Nov 07 11:45:13 2017 -0500
@@ -0,0 +1,1 @@
+((B:1,A:1)0:1,C:2);