Distributions of tips consistent with a partition pair
Source:R/SplitFunctions.R
NPartitionPairs.Rd
NPartitionPairs()
calculates the number of terminal arrangements matching
a specified configuration of two splits.
Details
Consider splits that divide eight terminals, labelled A to H.
Bipartition 1: | ABCD:EFGH | A1 = ABCD | B1 = EFGH |
Bipartition 2: | ABE:CDFGH | A2 = ABE | B2 = CDFGH |
This can be represented by an association matrix:
A2 | B2 | |
A1 | AB | C |
B1 | E | FGH |
The cells in this matrix contain 2, 1, 1 and 3 terminals respectively; this
four-element vector (c(2, 1, 1, 3)
) is the configuration
implied by
this pair of bipartition splits.
Examples
NPartitionPairs(c(2, 1, 1, 3))
#> [1] 12