Description Usage Arguments Details References Examples
Plot community or trait data on phylogeny to visualise differences in structure between traits or sites. Use colours to distinguish groups and alpha to distinguish abundances (works like rainbow())
1 2 |
cmatrix |
community/trait data matrix (cols taxa, rows sites) |
tree |
phylogenetic tree (ape class) |
groups |
trait or site groups |
No details
No references yet! https://github.com/DomBennett/MoreTreeTools.
1 2 3 4 5 6 7 8 | # Generate a balanced tree
tree <- compute.brlen (stree (16, 'balanced'))
# Generate random community data, 2 of 3 different communities
cmatrix <- matrix (round (runif (16*6, 0, 2)), nrow = 6, byrow = TRUE)
colnames (cmatrix) <- tree$tip.label
rownames (cmatrix) <- paste0 ('site_', 1:6)
# Plot community, specify group identitiy of each of the 6 sites
commplot (cmatrix, tree, groups = c (1,1,2,2,3,3))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.