Home
Reading
Searching
Subscribe
Sponsors
Statistics
Posting
Contact
Spam
Lists
Links
About
Hosting
Filtering
Features Download
Marketing
Archives
FAQ
Blog
 
Gmane
From: Jason Stajich <jason.stajich <at> gmail.com>
Subject: Re: Converting newick to nexus
Newsgroups: gmane.comp.lang.perl.bio.general
Date: Thursday 19th September 2013 18:15:19 UTC (over 3 years ago)
Johan -

I worry that this really won't be best solved in Bio::TreeIO tree modules
which are really written around streaming trees through not writing into a
compact format which pretty much requires having the whole set of trees in
memory. 

There are other efforts like Bio::Nexus (http://sourceforge.net/projects/bionexus/)
which could solve it better as it is intended to deal with the Nexus format
more completely, what we handle in Bio::TreeIO .

But that isn't to say someone couldn't try and work on it for Bio::TreeIO
parser. I personally have no bandwidth for this at the moment but maybe it
can be written into a project idea for the bioperl wiki to recruit someone
to work on it.

Jason

On Sep 17, 2013, at 1:21 PM, nylander <[email protected]> wrote:

> Dear Jason,
> 
> Unfortunately, this issue is perhaps a bit more complicated than just
> omitting the nexus header ('#NEXUS') after the first tree is printed. As
> soungalo pointed out, both the header AND the translation table is
repeated
> for every tree. This makes the output file larger than (perhaps)
necessary.
> 
> Optimally (and I think this is what soungalo wanted), the output should
> contain only a single translation table, and all trees should be written
to
> the same tree block (cf. the output from phylogenetic MCMC software
MrBayes,
> PhyloBayes, etc). This is only possible if all trees contain the same tip
> labels. Hence, all trees needs to be checked before the trees can be
printed
> in a single tree block. As implemented now, each translation table is
> created by parsing the order of tip labels in each individual tree. This
> makes sense if the trees might differ in size and/or labels. But again,
if
> we have many thousands of trees with the same set of tip labels,
repeating
> the translation table should be avoided.
> 
> I know that an efficient and "optimal" (see above) nexus tree writer is
> wanted by many, but I'm unsure how much effort that is involved in order
to
> handle the multi tree issue.
> 
> Yours
> Johan
> 
> 
> 
> 
> --
> View this message in context: http://bioperl.996286.n3.nabble.com/Converting-newick-to-nexus-tp17013p17153.html
> Sent from the Bioperl-L mailing list archive at Nabble.com.
> _______________________________________________
> Bioperl-l mailing list
> [email protected]
> http://lists.open-bio.org/mailman/listinfo/bioperl-l

Jason Stajich
[email protected]
[email protected]
 
CD: 3ms