Biopython newick treeio removes comments
1
1
Entering edit mode
3.4 years ago
Bill Pearson ★ 1.0k

I have a biopython program that uses newick NHX extensions to pass information to the "R" tree plotting program ggtree. I am certain this used to work, but with the current version of biopython, it does not seem possible to write arbitrary comments in newick output.

(1) Am I confused, has BioPython phylo.write('newick') never supported NHX comments? (2) is there an option for phylo.write() to write out the comment string?

biopython phylo.write • 638 views
ADD COMMENT
5
Entering edit mode
3.4 years ago
Bill Pearson ★ 1.0k

This is occurring because of a typo in the BioPython Phylo/NewickIO.py code (line 87), where the word "comment" is mis-spelled "coment". Fixing the typo fixes the problem. I have opened an issue on GitHub.

ADD COMMENT

Login before adding your answer.

Traffic: 2503 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6