Learn R Programming

phytools (version 0.7-20)

linklabels: Function to add tip labels to a plotted tree with linking lines

Description

Function adds tip labels to a plotted tree by drawing curved, bent, or straight linking lines.

Usage

linklabels(text,tips,link.type=c("bent","curved","straight"),
   ...)

Arguments

text

text string or vector to be used as labels.

tips

node numbers (indices) for the tips to be labeled.

link.type

manner in which to draw the linking lines.

...

optional arguments, including cex, lty, lwd, and col.

Value

This function annotates a plot.

Details

The idea underlying this function is that the user should first plot the tree without tip labels, but set the area of the plotting device to be sufficient to accommodate the tip labels once they have been added. The function then can be called to add tip labels connected by linking lines to the tips of the plotted tree.

References

Revell, L. J. (2012) phytools: An R package for phylogenetic comparative biology (and other things). Methods Ecol. Evol., 3, 217-223.

See Also

cladelabels, nodelabels, tiplabels