sackinI: Calculation of the Sackin index for rooted trees

Description Usage Arguments Value Author(s) References Examples

View source: R/sackinI.R

Description

This function calculates the Sackin index S(T) for a given rooted tree T. The tree must not necessarily be binary. S(T) is defined as

S(T)=∑_{x in V_L(T)} depth(x)=∑_{u in V_in(T)} (n_u)

in which V_L(T) denotes the leaf set of T, depth(x) denotes the depth of the leaf x, V_in(T) denotes the set of inner vertices in T and n_u denotes the number of leaves in the pending subtree that is rooted at u. The Sackin index is an imbalance index.

For n=1 the function returns S(T)=0 and a warning.

Usage

1
sackinI(tree)

Arguments

tree

A rooted tree in phylo format.

Value

sackinI returns the Sackin index of the given tree.

Author(s)

Luise Kuehn

References

M.J. Sackin. "Good" and "Bad" Phenograms. Systematic Biology, 21(2):225-226, 1972. doi: 10.1093/sysbio/21.2.225.

K.-T. Shao and R.R. Sokal. Tree Balance. Systematic Zoology, 39(3):266, 1990. doi: 10.2307/2992186.

Examples

1
2
tree <- ape::read.tree(text="((((,),),(,)),(((,),),(,)));")
sackinI(tree)

treebalance documentation built on Oct. 17, 2021, 5:06 p.m.