weighL1dist {treebalance} | R Documentation |
Calculation of weighted l1 distance index for rooted binary trees
Description
This function calculates the weighted l1 distance index for a
given rooted binary tree
.
is defined as
in which denotes the
number of leaves of
,
denotes the frequency of pending subtrees
of size
in
and
is the expected number of
pending subtrees of size
under the Yule model, i.e.
if
and otherwise
.
For the function returns
.
For details on the weighted l1 distance index, see
also Chapter 24 in "Tree balance indices: a comprehensive survey" (https://doi.org/10.1007/978-3-031-39800-1_24).
Usage
weighL1dist(tree)
Arguments
tree |
A rooted binary tree in phylo format. |
Value
weighL1distI
returns the weighted l1 distance index of the given tree.
Author(s)
Sophie Kersting
References
M. G. Blum and O. Francois. On statistical tests of phylogenetic tree imbalance: The Sackin and other indices revisited. Mathematical Biosciences, 195(2):141-153, 2005. doi: 10.1016/j.mbs.2005.03.003.
Examples
tree <- ape::read.tree(text="((((,),),(,)),(((,),),(,)));")
weighL1dist(tree)