Repository navigation
Calculating consistency index
There is a really nice paper that describes how to calculate the Consistency Index much better than I can. However, since HomoplasyFinder relies entirely upon the Consistency Index I think a brief description is necessary.
The Consistency Index is calculated on each site in the alignment independently. If we have a single phylogeny of 5 sequences:
1 3 4
| | 5 |
--- | |
| ---
| | 2
------- |
| |
---------
|
For a single site in the alignment, the nucleotide present at one site in each sequence can be annotated onto the tips of the phylogeny.
A A A
| | G |
--- | |
| ---
| | T
------- |
| |
---------
|
To calculate the Consistency Index the possible nucleotide set for each internal node on the phylogeny must be determined. There are two rules:
- If the descendant nodes of an internal node share nucleotides, then the shared nucleotides will be assigned to current internal node
- If the descendant nodes of an internal node don't share any nucleotides, then the nucleotides of each descendant node will be combined into a set and assigned to the current internal node
With these two rules, the possible nucleotides for the internal nodes for the current site can be assigned to the phylogeny:
A A A
| | G |
--- | |
A ---
| G,A
| |
------- T
A |
| |
---------
A,T
|
The minimum number of changes that are necessary to explain the pattern of nucleotides at the tips of the phylogeny, is equal to the number of times Rule 2 was true (twice).
For the current site the Consistency Index can be calculated using the following formula:
Number of nucleotides at site - 1 3 - 1 2
Consistency index = --------------------------------- = ----- = --- = 1
Minimum number of changes on tree 2 2
A Consistency Index of one indicates that the nucleotides observed at the site are entirely consistent with the phylogeny. Values decreasing towards zero indicate increasingly more inconsistency, until zero which means the nucleotides at the site are entirely inconsistent with the current site.