N1Spr: Number of trees one SPR step away

View source: R/Combinatorics.R

N1SprR Documentation

Number of trees one SPR step away

Description

N1Spr() calculates the number of trees one subtree prune-and-regraft operation away from a binary input tree using the formula given by \insertCiteAllen2001;textualTreeTools; IC1Spr() calculates the information content of trees at this distance: i.e. the entropy corresponding to the proportion of all possible n-tip trees whose SPR distance is at most one from a specified tree.

Usage

N1Spr(n)

IC1Spr(n)

Arguments

n

Integer vector specifying the number of tips in a tree.

Value

N1Spr() returns an integer vector denoting the number of trees one SPR rearrangement away from the input tree..

IC1Spr() returns an numeric vector giving the phylogenetic information content of trees 0 or 1 SPR rearrangement from an n-leaf tree, in bits.

References

\insertAllCited

Examples

N1Spr(4:6)
IC1Spr(5)


TreeTools documentation built on June 22, 2024, 9:27 a.m.