plotTree
¶
Plot a tree
Description¶
Plot a tree
Usage¶
plotTree(tree, prune = NULL, keepSeqs = NULL, col = "black",
leafCol = col, leafLabels = NULL, timeScale = 1, drawSpr = FALSE,
sites = NULL, chromStart = NULL, chromEnd = NULL,
ylab = "Generations", logScale = FALSE, ylim = NULL, add = FALSE,
mar = c(8, 4, 1, 1), mod = NULL, cex.leafname = 0.8, ...)
Arguments¶
Argument |
Description |
---|---|
|
A newick string containing a tree |
|
A list of leafs to prune from the tree before plotting (Null means prune none) |
|
A list of leafs to keep in the tree (NULL means keep all) |
|
Either a character string (single value) giving color of tree. Or, a list giving color to plot each leaf branch. Internal branches will be plotted as “average” color among child leafs. |
|
If given, this can be a list assigning a color to each leaf name (individual names also work if haploid names are in the form indName_1 and indName_2) |
|
A list indexed by the leaf names in the tree, giving the label to display for each leaf name. If NULL, the leaf names are displayed. |
|
multiply all branches by this value |
|
If TRUE, draw the SPR event that turns each tree into the next one |
|
If given, draw mutation events on tree |
|
The start coordinate of the tree region (1-based; only used if SITES not null) |
|
The end coordinate of the tree region |
|
label for y axis |
|
If TRUE, plot in log scale |
|
Range for y axis (default; use range of tree) |
|
If TRUE, do not create a new plot |
|
Margins for plot |
|
(Advanced; for use with multi-population version of ARGweaver) A model file read in with the function readPopModel, will draw population model underneath tree |
|
Character size of leaf names |
|
Passed to plot function |
Note¶
This creates a new plot for each tree. If plotting to the screen, probably want to call par(ask=TRUE) first.