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

Bug in get_distance() with flag topology_only=True in ete3 #740

Open
lenacoll opened this issue Feb 7, 2024 · 0 comments
Open

Bug in get_distance() with flag topology_only=True in ete3 #740

lenacoll opened this issue Feb 7, 2024 · 0 comments

Comments

@lenacoll
Copy link

lenacoll commented Feb 7, 2024

tree.get_distance(target, target2, topology_only=True) should (according to the documentation) return the number of nodes connecting target and target2. It does not correctly do this, as shown in this example:

tree = Tree("((A,B), C);")
node2 = tree.get_common_ancestor("A", "B")

Then:

tree.get_distance(tree, node2, topology_only=True)

1.0

tree.get_distance(node2, tree, topology_only=True)

0.0

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

1 participant