Learn R Programming

rotl (version 0.5.0)

strip_ott_ids: Strip OTT ids from tip labels

Description

Strip OTT ids from tip labels

Usage

strip_ott_ids(tip_labels)

Arguments

tip_labels
a character vector containing tip labels (most likely the tip.label element from a tree returned by tol_induced_subtree

Value

  • A character vector containing the contents of tip_labels with any OTT ids removed.

Examples

Run this code
genera <- c("Perdix", "Clangula", "Dendroica", "Cinclus", "Stellula", "Struthio")
tr <- tol_induced_subtree(ott_ids=c(292466, 501678, 267845, 666104, 316878, 102710, 176458))
tr$tip.label %in% genera
tr$tip.label <- strip_ott_ids(tr$tip.label)
tr$tip.label %in% genera

Run the code above in your browser using DataLab