prune2data: Prunes a phylogenetic tree to match a vector (e.g. of species names in a dataset)
Description
Takes a phylo object and vector of names to be matched to tip labels and returns a pruned phylogeny containing only tip labels that match those in the vector.
Usage
prune2data(tree, species)
Value
Returns a phylogenetic tree of the class 'phylo' containing only tips whose labels match the input vector (species)
Arguments
tree
Phylogenetic tree of class 'phylo'.
species
Vector of names to be matched against tip labels of the tree.