sub.taxa.label: Substitute the tip labels of a phylogenetic tree

View source: R/sub.taxa.label.R

sub.taxa.labelR Documentation

Substitute the tip labels of a phylogenetic tree

Description

Substitute the tip labels of a phylogenetic tree according to a reference data table.

Usage

sub.taxa.label(tree, dat)

Arguments

tree

Phylogenetic tree

dat

A dataframe with the first column the tip labels and the second column the new names.

Value

A Phylogenetic tree with the tip labels substituted

Author(s)

Jinlong Zhang jinlongzhang01@gmail.com

See Also

read.tree

Examples


library(ape)
data(bird.families)
tips <- bird.families$tip.label
abr <- paste("fam",1:length(tips), sep = "")
dat <- data.frame(tips, abr)
ntree <- sub.taxa.label(bird.families, dat)


helixcn/phylotools documentation built on Oct. 11, 2024, 4:11 a.m.