Description Usage Arguments Author(s) See Also Examples
This function represents a phylogeny as a fan, using circles to
provide a legend for distances and optionally colored symbols to
represent traits associated to the tips of the tree. This function
uses and is compatible with ape's plot.phylo
.
1 2 3 4 5 |
phy |
a tree in |
traits |
an optional data.frame of traits. |
col.tips.by |
an optional vector used to define colors for tip
labels; if unamed, must be ordered in the same order as
|
col.pal |
a function generating colors according to a given palette; several palettes can be provided as a list, in the case of several traits; the first palette is always reserved for the tip colors; this argument is recycled. |
circ.n |
the number of circles for the distance annotations. |
circ.bg |
the color of the circles. |
circ.unit |
the unit of the circles; if NULL, determined automatically from the data. |
legend |
a logical specifying whether a legend should be plotted; only one legend is displayed, with priority to tip colors first, and then to the first trait. |
leg.posi,leg.title,leg.bg |
position, title and background for the legend. |
traits.inset |
inset for positioning the traits; 1 corresponds to the circle crossing the furthest tip, 0 to the center of the plot. |
traits.space |
a coefficient indicating the spacing between traits. |
traits.pch,traits.cex |
type and size of the symbols used for the traits; recycled if needed. |
alpha |
alpha value to be used for the color transparency, between 0 (invisible) and 1 (plain). |
axis |
a logical indicating whether an axis should be displayed. |
... |
further arguments to be passed to plot methods from
|
Thibaut Jombart tjombart@imperial.ac.uk
table.phylo4d
for non-radial plots.
The phylo4d class for storing phylogeny+data
.
plot.phylo
from the ape
package.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | if(require(ape) && require(phylobase) && require(adegenet)){
data(lizards)
tre <- read.tree(text=lizards$hprA) # make a tree
## basic plots
bullseye(tre)
bullseye(tre, lizards$traits)
## customized
par(mar=c(6,6,6,6))
bullseye(tre, lizards$traits, traits.cex=sqrt(1:7), alpha=.7,
legend=FALSE, circ.unit=10, circ.bg=transp("black",.1),
edge.width=2)
}
|
Loading required package: ade4
Registered S3 method overwritten by 'spdep':
method from
plot.mst ape
Loading required package: ape
Loading required package: phylobase
Attaching package: ‘phylobase’
The following object is masked from ‘package:ape’:
edges
Loading required package: adegenet
/// adegenet 2.1.3 is loaded ////////////
> overview: '?adegenet'
> tutorials/doc/questions: 'adegenetWeb()'
> bug reports/feature requests: adegenetIssues()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.