Learn R Programming

evobiR (version 1.0)

HighLevelTree: Prune a phylogeny to a higher taxonomic levels.

Description

This function takes a species level tree and prunes it so only a single representative of each clade, e.g. genus or family, is present.

Usage

HighLevelTree(taxa.table, tree, cur.tips, new.tips)

Arguments

taxa.table
a character matrix with columns containing the current tips of the tree and additional columns containing their assigned genera, family, tribe, etc.
tree
the current species level tree
cur.tips
a number indicating which column contains the current tip names
new.tips
a number indicating which column contains the names for the taxonomic level that you would like to prune the tree to.

Value

  • returns and object of the class "phylo"

References

http://www.uta.edu/karyodb/evobiR/

See Also

GetTaxonomy

Examples

Run this code
data(species.tree)
data(taxa.table)

family.tree <- HighLevelTree(taxa.table, species.tree, 1, 2)
genus.tree <- HighLevelTree(taxa.table, species.tree, 1, 3)

Run the code above in your browser using DataLab