-
Notifications
You must be signed in to change notification settings - Fork 76
to_nexus()
does not emit compliant Nexus
#1785
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Comments
@jeetsukumaran Thanks for this excellent issue report. Would you like to submit a PR to fix these issues? Contributions to tskit are recognised by authorship on the upcoming tskit paper. |
(No directly involved here, but related is #1671) |
That sounds great! I would love to contribute! I'll update you (and this issue) when I make progress |
The basic issue was fixed in #1835. This issue can be closed when we add dendropy based tests of the functionality to confirm. |
Closes tskit-dev#1785 Add dendropy to various requirements lists Also refactor the tests to use pytest a little better
Closes tskit-dev#1785 Add dendropy to various requirements lists Also refactor the tests to use pytest a little better
Closes tskit-dev#1785 Add dendropy to various requirements lists Also refactor the tests to use pytest a little better
As per the above, the Nexus string emitted by tskit is not standard Nexus and cannot be parsed by most software.
There are a two different problems.
(1) The TAXA block requires a
DIMENSIONS NTAX=##
statement.(2) The list of taxon labels should be separated by SPACES, NOT by commas.
The
TreeSequence.to_nexus()
statement currently emits:Multiple program fail to parse this, including PAUP, BEAST, and, in fact, most phylogenetic programs and processing libraries.
Adding a DIMENSIONS statement and separating the taxon labels using spaces makes this not only compliant with standard Nexus, but also readable by most Nexus-supporting phylogenetic programs (whatever else their idiosyncracies! :) )
The text was updated successfully, but these errors were encountered: