Generate a pairwise matrix of a fixation indices between samples.
🔙 To the main page of anvi’o programs and artifacts.
This program generates a matrix of the pairwise fixation indices (FST) between your samples.
What’s a fixation index?
As described in the Infant Gut Tutorial, the fixation index is a measure of the distance between two populations, based on their sequence variants (usually SNVs). Specifically, the fixation index is the ratio between the variance in allele frequency between subpopulations and the variance in the total population.
In anvi’o, the fixation index is calculated in accordance with Schloissnig et al. (2013)’s work to allow variant positions with multiple competing alleles.
There are two ways to run this program.
Input 1: Variability Profile
anvi-gen-fixation-index-matrix --variability-profile variability-profile \ --output-file my_matrix.txt
This will use the information in your variability-profile-txt to generate the fixation index for each of the pairwise sample comparisons, and store the results in a fixation-index-matrix named
Input 2: Anvi’o databases
Instead of providing a variability-profile, you can instead provide the inputs to anvi-gen-variability-profile and let anvi’o do all of the work for you. Specifically, this means providing a contigs-db and profile-db pair to find your variability positions and a specific subset to focus on in any of these ways:
- Provide a list of gene caller IDs (as a parameter with the flag
--gene-caller-idsor in a file with one ID per line with the flag
- Provide a list of splits (in a splits-txt)
- Provide a collection and bin
Additionally, you can add structural annotations by inputting a structure-db (and focus only on genes with structural annotations with the flag
--only-if-structure) or choose to focus on only a subset of your samples by providing a file of samples of interest.
When doing this, you can also set the variability engine to get the fixation index for SCVs (
--engine CDN) or SAAVs (
You can find more information about these parameters on the page for anvi-gen-variability-profile.
While a fixation index is usually between 0 and 1, it is possible for an index to be negative (usually because of out-breeding). By default, anvi’o sets these negative values to 0, but you can choose to keep the negative values with the flag
Edit this file to update this information.
Are you aware of resources that may help users better understand the utility of this program? Please feel free to edit this file on GitHub. If you are not sure how to do that, find the
__resources__ tag in this file to see an example.