View source: R/plot_tree_annots.R
plot_tree | R Documentation |
This is similar to APE plot.phylo but returns useful information on each branch to facilitate annotation of tree. Be careful not to unintentionally supply population scale simpop
plot_tree(
tree,
direction = "down",
cex.label = 1,
offset = 0,
b_do_not_plot = FALSE,
lwd = 1,
bars = NULL,
default_edge_color = "darkgrey",
ymax = NULL,
cex.terminal.dots = 0,
mar = NULL,
b.add.scale = TRUE,
left.margin.prop = 0.1
)
tree |
phylo/simpop |
direction |
character. Only "down" is currently supported. |
cex.label |
numeric. Size of tip labels (0 results in no tip labels) |
offset |
numeric (0-1). Fractional offset of tip labels from branch terminus |
b_do_not_plot |
Boolean. |
lwd |
numeric. Line width |
bars |
numeric. vector with named elements that should all match tip labels - adds barplot under tree. |
default_edge_color |
colour. |
ymax |
numeric max y |
cex.terminal.dots |
numeric - size of terminal dots |
mar |
numeric vector Override default resetting of mar as in par("mar") |
b.add.scale |
Boolean - whether to add scale axis |
left.margin.prop |
numeric - leaves this fraction empty on left |
simpop object
test=rtree(20)
tree=plot_tree(test,cex.terminal=0.5,bars=sapply(sprintf("s%d",seq(2,20,2)),function(x) runif(1)))
node_labels(tree)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.