Re: [R-sig-phylo] collapsing sets of nodes based on label values

2020-05-22 Thread Emmanuel Paradis
Hi, Brian is 100% right about interpreting bootstrap values. When the tree is input into R with read.tree() or read.nexus(), these values are attached to the nodes but they relate to their subtending branches. The function root() has the option 'edgelabel' to specify whether these node labels

Re: [R-sig-phylo] collapsing sets of nodes based on label values

2020-05-22 Thread Brian O'Meara
You might need to reindex each time, something like (pseudocode): bad.nodes <- function_to_get_node_numbers_with_support_less_than_90(phy) while(length(bad.nodes>0)) { phy <- collapse.to.star(phy, bad.nodes[1]) bad.nodes <- function_to_get_node_numbers_with_support_less_than_90(phy) } But

[R-sig-phylo] collapsing sets of nodes based on label values

2020-05-22 Thread Karla Shikev
Dear all, I'm surprised I could not find a simple function to do this in any of the packages I know. I just want to take a tree with node labels (e.g. bootstrap values from a RAxML analysis) and collapse all nodes with support values below, say, 90%. I tried to do this recursively using