Finds the shortest path between two nodes in a tree
shortestPath(x, node1, node2)# S4 method for phylo4
shortestPath(x, node1, node2)
# S4 method for phylo
shortestPath(x, node1, node2)
a vector of nodes indcating the shortest path between 2 nodes
a tree in the phylo4, phylo4d or phylo format
a numeric or character (passed to getNode)
indicating the beginning from which the path should be calculated.
a numeric or character (passed to getNode)
indicating the end of the path.
Given two nodes (i.e, tips or internal nodes), this function
returns the shortest path between them (excluding node1 and
node2 as a vector of nodes.
getNode