Description Usage Arguments Note Author(s) See Also Examples
This functions can be used to highlight clades/lineages in a plot of a phylogenetic tree with bars, possibly accompanied by additional text.
1 2 3 |
phy |
an object of class |
nodes |
a vector of mode |
bars |
|
barcol |
a vector of mode |
barwd |
a vector of mode |
text |
a string giving the text to be plotted to the right of the clade. Can be set to |
textcol |
a vector of mode |
srt |
numeric, the rotation of text in degrees. |
cex |
numeric character expansion factor; multiplied by |
offset |
a vector of length one or two giving the offset for plotting bars and their labels. If two offset values are given, the first is used for the spacing between tip labels (or other previously plotted elements) and bars, and the second offsets the bar labels from the bars. |
align |
a vector with two possible values that controls the alignment of bars: |
s |
a vector of mode |
... |
further graphical parameters may also be supplied as arguments. |
Do not expect clade.bars
to work with all flavors of plot.phylo
: Currently, clade.bars
works well only with types "phylogram"
and "cladogram"
in directions "rightwards"
, "leftwards"
, and "upwards"
. Further extensions of the code are always welcome!
Christoph Heibl
plot.phylo
for plotting of phylogenetic trees; box.tips
and box.clades
for plotting boxes around tips/clades; tip.color
and edge.color
for coloring tips labels or braches/edges in a plotted tree.
1 2 3 4 5 6 7 8 9 10 11 | ## DATA: phylogentic relationships of bird orders:
## -----------------------------------------------
data(viperidae)
genera <- list("Montivipera", "Macrovipera", "Vipera", "Daboia")
genera.mrca <- noi(viperidae, regex = TRUE, genera)
cls <- c("yellow", "skyblue", "orange", "pink")
## EXAMPLE 1: the defaults
## -----------------------
plot(viperidae)
clade.bars(viperidae, genera.mrca)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.