View source: R/treeplyr_functions.R
treeply | R Documentation |
treedata
objectApplies a function to the phylogeny in a treedata
object. If the order of
tips are changed, or if tips are dropped, then the data are automatically reordered
to match the tree.
treeply(tdObject, ...) ## S3 method for class 'treedata' treeply(tdObject, FUN, ...)
tdObject |
An object of class |
... |
Additional arguments |
FUN |
A function that operates on an object of class 'phylo' |
An object of class treedata
data(anolis) td <- make.treedata(anolis$phy, anolis$dat) td2 <- treeply(td, drop.tip, 1:50) par(mfrow=c(1,2)) plot(td$phy) plot(td2$phy)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.