Learn R Programming

TreeSearch (version 0.3.2)

RenumberTips: Reorder tips

Description

RenumberTips(tree, tipOrder) sorts the tips of a phylogenetic tree such that the indices in tree$edge[, 2] correspond to the order of tips given in tipOrder

Usage

RenumberTips(tree, tipOrder)

Arguments

tree

A tree of class phylo.

tipOrder

A character vector containing the values of tree$tip.label in the desired sort order

Examples

Run this code
# NOT RUN {
data(Lobo) # Loads the phyDat object Lobo.phy
tree <- RandomTree(Lobo.phy)
tree <- RenumberTips(tree, names(Lobo.phy))

# }

Run the code above in your browser using DataLab