Genotype Frequency Calculator
Enter the counts of AA, Aa, and aa individuals to compute each genotype frequency and the allele frequencies p (A) and q (a) for population-genetics and Hardy–Weinberg analysis.
Input Data
Results
At a glance:Genotype frequency is the proportion of a particular genotype among all individuals in a population. Enter the counts of AA, Aa, and aa; total individuals N = AA + Aa + aa. The three genotype frequencies are f(AA)=AA÷N, f(Aa)=Aa÷N, f(aa)=aa÷N, summing to 1. Allele frequencies come from counting alleles: each AA contributes 2 A, each Aa contributes 1 A and 1 a, each aa contributes 2 a, with total alleles 2N. So p = (2·AA + Aa) ÷ (2·N) and q = (2·aa + Aa) ÷ (2·N), where p + q = 1.
Formula
Total individuals: N = AA + Aa + aa.
Genotype frequencies: f(AA)=AA÷N, f(Aa)=Aa÷N, f(aa)=aa÷N (sum = 1).
Allele frequencies: p = (2·AA + Aa) ÷ 2N, q = (2·aa + Aa) ÷ 2N.
Check: p + q = 1.
$$p = \frac{2\cdot AA + Aa}{2N}$$$$q = \frac{2\cdot aa + Aa}{2N}$$$$p + q = 1$$How to Use
- Enter the observed counts of AA, Aa, and aa individuals.
- The tool instantly shows genotype frequencies and allele frequencies p, q.
- Use the p+q=1 check to verify the counts are consistent.
Example: genotype and allele frequencies (AA=320, Aa=160, aa=20, N=500)
| Item | Value | Note |
|---|---|---|
| f(AA) | 0.64 | 320 ÷ 500 |
| f(Aa) | 0.32 | 160 ÷ 500 |
| f(aa) | 0.04 | 20 ÷ 500 |
| p (A) | 0.80 | (640 + 160) ÷ 1000 |
| q (a) | 0.20 | (40 + 160) ÷ 1000 |
| p + q | 1.00 | Consistency check |
Genotype frequencies sum to 1; allele frequencies p + q = 1. If p+q ≠ 1, check the counts or whether multiple alleles are involved.
Case Studies
Simple trait with two alleles
A population sample: AA=320, Aa=160, aa=20, total N=500.
p = (2×320 + 160) ÷ 1000 = 800 ÷ 1000 = 0.8; q = (2×20 + 160) ÷ 1000 = 200 ÷ 1000 = 0.2, p+q=1.
Genotype frequencies: f(AA)=0.64, f(Aa)=0.32, f(aa)=0.04. The A allele dominant, appearing in 0.8 of alleles.
Estimating carrier rate from recessive disease
For a recessive disease, aa individuals are affected; suppose aa=1 in N=10000, AA=9991, Aa=8.
q = (2×1 + 8) ÷ 20000 = 10 ÷ 20000 = 0.0005; p ≈ 0.9995.
Heterozygous carriers Aa frequency = 2pq ≈ 2 × 0.9995 × 0.0005 ≈ 0.0009995 ≈ 0.1%, far above the 0.005% affected rate — most carriers show no symptoms, so carrier screening matters.
FAQ
What is the difference between genotype and allele frequency?
Genotype frequency is the proportion of a genotype (AA/Aa/aa) among all individuals; allele frequency is the proportion of an allele (A or a) among all alleles. There are N individuals but 2N alleles, so the two differ by a factor of 2 in counting. Allele frequency is the true driver of evolutionary change and population genetics.
Why count alleles as 2·AA + Aa?
Because each individual holds two alleles at one locus. AA contributes two A alleles, Aa contributes one A and one a, aa contributes two a. Totaling A alleles = 2·AA + Aa, and dividing by 2N (total alleles) gives p; likewise for q. This correctly weights diploid genotypes into the allele pool.
What does p + q = 1 mean?
When a locus has only two alleles A and a, their frequencies must sum to 1 (all alleles are either A or a). If p+q ≠ 1, the input counts are inconsistent, multiple alleles exist, or there is a miscount. The check is a quick validity test for your data.
How to estimate allele frequency when only phenotype is known?
If the recessive phenotype is visible, aa individuals = q², so first estimate q = √(aa frequency), then p = 1 − q, and heterozygous frequency 2pq. This is the classic Hardy–Weinberg application for recessive traits where heterozygotes are phenotypically hidden.
How does this relate to Hardy–Weinberg?
Genotype and allele frequencies are the input and equilibrium basis of Hardy–Weinberg. Observed genotype frequencies let you compute p and q; if genotype frequencies fit p², 2pq, q², the population is in HWE. Deviations suggest evolutionary forces (selection, drift, migration, non-random mating).
Related Tools
References
Content review: Calculatorism Science Team. Results are for reference only; please refer to the relevant authorities for the official figures.