phyx icon indicating copy to clipboard operation
phyx copied to clipboard

pxltr should preserve annotations if present

Open josephwb opened this issue 7 years ago • 8 comments

pxltr works well, but if the input is an annotated Nexus tree, the newick output does not include the annotations.

josephwb avatar Jul 17 '17 16:07 josephwb

Rethinking this one. Are Nexus annotations newick-compliant? Don't think so. Forget how this got brought up.

(If someone remembers, let me know! :bowtie:)

josephwb avatar Dec 05 '17 15:12 josephwb

@josephwb do you have an example with this? I can help tackle this but not exactly sure I understand it.

blackrim avatar Dec 16 '17 03:12 blackrim

This so old I forget! Also, must be pxrlt?

But I think the situation was this: you have, say, a BEAST tree with ugly labels. You use pxrlt to clean them up, but because a newick comes out all of your fancy Nexus node annotations (probabilities, rates, whatever) are lost, so when you open your tree in FigTree you cannot make it pretty.

But I guess this would be a an issue for most programs. Maybe a general solution is to have have Nexus as a possible output option? I am currently doing that for pxcltr.

I can look at this.

josephwb avatar Dec 16 '17 11:12 josephwb

Just curious if there are any updates on this?

coyotree avatar Aug 20 '20 21:08 coyotree

I would also like this functionality, but don't know if @josephwb had already assigned it to himself. @josephwb are you doing this?

blackrim avatar Aug 27 '20 15:08 blackrim

I am not currently working on this. Basically, we need a general Nexus tree writer that preserves the annotations. This should be made as an available output option for pxrlt and pxrmt and pxrr (maybe others?).

josephwb avatar Aug 27 '20 15:08 josephwb

I would be interested in this if it does ever come up again. I have an annotated Nexus treefile from pxcontrates in which I would like to preserve the ancestral state reconstruction values, but of course running it through pxrlt got rid of them. I know for now that the thing to do is use pxrlt on the starting tree that I run through pxcontrates but I could foresee more general needs for this, like with BEAST output as stated above.

sbrobeson avatar Jun 06 '24 00:06 sbrobeson

@sbrobeson Thanks for pinging this issue. I agree it would be of use. I am working on several other issues, so if anyone else wants to run with this, that would be great. Otherwise, I can come around to this at some point.

josephwb avatar Jun 06 '24 01:06 josephwb