fix.poly | R Documentation |
The function either collapses clades under a polytomy or resolves polytomous clades to non-zero length branches, dichotomous clades.
fix.poly(tree,type=c("collapse","resolve"),node=NULL,tol=1e-10,random=TRUE)
tree |
a phylogenetic tree. |
type |
either 'collapse' to create polytomies to one or more specific nodes or 'resolve' to resolve (fix) all the polytomies within the tree or to one or more specific nodes. |
node |
the node in the tree where a polytomy should be created or fixed,
either. If |
tol |
the tolerance to consider a branch length significantly greater
than zero, set at 1e-10 by default. If |
random |
a logical value specifying whether to resolve the polytomies
randomly (the default) or in the order they appear in the tree (if
|
Under type='resolve'
polytomous clades are resolved adding
non-zero length branches to each new node. The evolutionary time attached
to the new nodes is partitioned equally below the dichotomized clade.
A phylogenetic tree with randomly fixed (i.e. type='resolve'
)
polytomies or created polytomies (i.e. type='collapse'
).Note,
tip labels are ordered according to their position in the tree.
Silvia Castiglione, Pasquale Raia, Carmela Serio
Castiglione, S., Serio, C., Piccolo, M., Mondanaro, A., Melchionna, M., Di Febbraro, M., Sansalone, G., Wroe, S., & Raia, P. (2020). The influence of domestication, insularity and sociality on the tempo and mode of brain size evolution in mammals. Biological Journal of the Linnean Society,132: 221-231. doi:10.1093/biolinnean/blaa186
## Not run:
require(ape)
data("DataCetaceans")
DataCetaceans$treecet->treecet
# Resolve all the polytomies within Cetaceans phylogeny
fix.poly(treecet,type="resolve")->treecet.fixed
par(mfrow=c(1,2))
plot(treecet,no.margin=TRUE,show.tip.label=FALSE)
plot(treecet.fixed,no.margin=TRUE,show.tip.label=FALSE)
# Resolve the polytomies pertaining the genus Kentriodon
fix.poly(treecet,type="resolve",node=221)->treecet.fixed2
par(mfrow=c(1,2))
plot(treecet,no.margin=TRUE,show.tip.label=FALSE)
plot(treecet.fixed2,no.margin=TRUE,show.tip.label=FALSE)
# Collapse Delphinidae into a polytomous clade
fix.poly(treecet,type="collapse",node=179)->treecet.collapsed
par(mfrow=c(1,2))
plot(treecet,no.margin=TRUE,show.tip.label=FALSE)
plot(treecet.collapsed,no.margin=TRUE,show.tip.label=FALSE)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.