Learn R Programming

phytools (version 2.3-0)

untangle: Attempts to untangle crossing branches for plotting

Description

Attempts to "untangle" the branches of a tree that are tangled when plotting with plot.phylo, plotTree, or plotSimmap.

Usage

untangle(tree, method=c("reorder","read.tree"))

Value

An object of class "phylo" or "simmap", depending on the class of tree.

Arguments

tree

tree as an object of class "phylo" or "simmap".

method

method to use to attempt to untangle branches. method="reorder" uses two calls of reorder.phylo or reorderSimmap; method="read.tree" writes the tree to a text string and then reads it back into memory using read.tree.

Author

Liam Revell liam.revell@umb.edu

Details

Generally speaking, this function is wraps several different internal functions that might be use to fix a badly conformed "phylo" or "simmap" object.

References

Revell, L. J. (2024) phytools 2.0: an updated R ecosystem for phylogenetic comparative methods (and other things). PeerJ, 12, e16505.