I am using the ape
package in R
to make a phylogeny.
tree1 <-read.nexus("my_unrooted_tree.nex", tree.names = NULL)
I want to find the minimum number of internal nodes of my unrooted tree.
Using tree1$edge
I can could the number of ancestoral branches, but is there a way to do this automatically?