relabel_node | R Documentation |
Replaces existing tip labels with new labels.
relabel_node(phy, label, new_label)
phy |
A phylo object. |
label |
A vector of strings, the node labels to be replaced. |
new_label |
A vector of strings, the same length as |
library(ape)
tree <- relabel_with_names(get_glottolog_trees("Tangkic"))
tree2 <- apply_duplicate_suffixes(clone_tip(tree, "Yangkaal", subgroup = TRUE))
plot(tree2)
tree3 <- relabel_tip(tree2, c("Kangkalita", "Yangkaal-1", "Yangkaal-2"),
c("Gangalidda", "Yangkaal", "Yangarella"))
plot(tree3)
nodelabels(tree3$node.label)
tree4 <- relabel_node(tree3, c("Yangkaal", "Kayardild-Yangkaal"),
c("Yangkaralda", "Kayardild-Yangkaralda"))
plot(tree4)
nodelabels(tree4$node.label)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.