Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support extended Newick? #78

Closed
cossio opened this issue Jan 21, 2023 · 4 comments
Closed

Support extended Newick? #78

cossio opened this issue Jan 21, 2023 · 4 comments

Comments

@cossio
Copy link
Contributor

cossio commented Jan 21, 2023

It seems the package cannot read extended Newick format trees?

I'm having trouble in particular reading trees stored in RFAM (https://docs.rfam.org/en/latest/api.html?highlight=nhx#tree-data). For example,

http://rfam.org/family/RF00360/tree/

@mkborregaard
Copy link
Member

Is there a specification for extended newick? Quick search brings up https://bmcbioinformatics.biomedcentral.com/articles/10.1186/1471-2105-9-532

@richardreeve
Copy link
Member

@cossio - I'm sure it's too late now, but for what it's worth, I'm finally finding some time to rewrite the parser. I'm hoping to write an improved nexus/newick parser that will allow you to import and export trait values using the same format that BEAST uses - https://beast.community/nexus_metacomments.html - but I haven't heard of RFAM and unless there's a clear definition of it somewhere, I'm unlikely to adopt that too as I've never seen it before.

@richardreeve
Copy link
Member

The parser reads and writes the metacomment format to set node and branch data, but given there's no obvious specification for this RFAM format, and it actually doesn't look much like the standard newick or nexus tree format, it doesn't seem likely we'll be able to support it, sorry.

@richardreeve
Copy link
Member

Interestingly I've just found a definition for extended newick on wikipedia - https://en.wikipedia.org/wiki/Newick_format#Extended_Newick - but it looks nothing like this! I've also found nhx format in the same entry - https://en.wikipedia.org/wiki/Newick_format#New_Hampshire_X_format - but that also looks nothing like this. I think it's a bit of a minefield, and I'm not sure it'll be possible to support any of them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants