[Biojava-l] Newick/Nexus processing of non-binary trees

Tiago Antão tiagoantao at gmail.com
Fri Nov 6 14:40:00 UTC 2009


2009/11/6 Richard Holland <holland at eaglegenomics.com>:
> If that's true, sounds like it's broke. Is the old code easily modified to
> suit arbitrary numbers of children?

I don't think so. It uses a stack based solution, so it would not be
possible to know when a part of the stack belongs to the current node
being processed or something else on the tree.
One could put markers on the stack or something, but it would become a
bit convoluted. I would suppose a recursive implementation would be
cleaner here.

My suggestion: for somebody else to verify my findings. I might be
doing something stupidly wrong. Maybe things are correct. Just a
simple tree like (1,2,3) (as long as it is not binary) - should expose
the problem.



More information about the Biojava-l mailing list