We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
With ete3, it is easy to delete/collapse internal branches based on support value:
ete3
from ete3 import Tree, TreeNode tree = Tree() A = tree.add_child(name='A', support=100) A1 = A.add_child(name='A1') A2 = A.add_child(name='A2') B = tree.add_child(name='B', support=50) C = B.add_child(name='C') D = B.add_child(name='D') print(tree.get_ascii(show_internal=True)) # /-A1 # /A| # | \-A2 # --| # | /-C # \B| # \-D # traversing nodes to remove internal nodes with support less than 95 for node in tree.traverse(): if not node.is_leaf() and not node.is_root(): if node.support < 95: node.delete() print(tree.get_ascii(show_internal=True)) # /-A1 # /A| # | \-A2 # --| # |--C # | # \-D
The text was updated successfully, but these errors were encountered:
Add feature #2, add option to collapse low support branches and outpu…
056aa64
…t modified Newick file
Merge pull request #5 from peterk87/feature/2-collapse-low-support-br…
95ae1ea
…anches Add feature #2, add option to collapse low support branches and to output modified Newick file
Fixed in #5
Sorry, something went wrong.
peterk87
No branches or pull requests
With
ete3
, it is easy to delete/collapse internal branches based on support value:The text was updated successfully, but these errors were encountered: