KlausVigo / phangorn

Phylogenetic analysis in R
http://klausvigo.github.io/phangorn/
202 stars 38 forks source link

treedist() no longer working for non-binary trees #128

Closed jc17659 closed 2 years ago

jc17659 commented 2 years ago

I have recently returned to some code that previously ran fine using the treedist() function on a large list of unrooted consensus trees against a benchmark topology. It now, however, does not run. When I pull out a lone tree to compare to the benchmark and try to use the function I get the error message:

Error in !is.binary(tree1) | !is.binary(tree2) : non-conformable arrays

has something changed in using non-binary trees for the function? How could I get around this?

KlausVigo commented 2 years ago

Hi @jc17659, there weren't any recent changes in treedist(). The error message looks strange. Maybe something got wrong with the construction of the consensus tree? Can you send me the trees? Regards, Klaus

jc17659 commented 2 years ago

I think I have found the issue, I was reading in the trees incorrectly it seems, my own function was causing the issue - thanks for you time and the quick reply. They would plot but in R but not work in any functions it seems

KlausVigo commented 2 years ago

That's good! I close the issue. Feel free to reopen it, if there are more problems.