Hardy-Weinberg Equilibrium Calculators

0 calculators tagged with “Hardy-Weinberg Equilibrium

Hardy-Weinberg equilibrium (HWE) is a null model in population genetics stating that in an idealized population, allele frequencies remain constant from generation to generation, and genotype frequencies follow: AA = p², Aa = 2pq, aa = q², where p + q = 1 for allele frequencies. This equilibrium is reached after just one generation of random mating and is maintained as long as five conditions hold: large population size; random mating; no mutation; no gene flow; no natural selection. Deviation from HWE indicates that at least one of these conditions is violated — indicating evolution is occurring or genotyping errors are present.

All Calculators

No calculators found for this topic.

Hardy-Weinberg Formula

p² + 2pq + q² = 1

p = frequency of dominant allele (A); q = frequency of recessive allele (a); p + q = 1. Genotype frequencies: AA = p²; Aa = 2pq; aa = q². Heterozygote frequency is maximum at p = q = 0.5 → 2pq = 0.50.

Conditions for HWE

  1. Large (effectively infinite) population — no genetic drift
  2. Random mating — no assortative mating or inbreeding
  3. No mutation (μ → 0)
  4. No gene flow — isolated population
  5. No natural selection — all genotypes equally fit

Chi-Square Test for HWE

χ² = Σ (O − E)²/E; df = 1 for biallelic locus. Expected counts from p² and q² calculated from observed allele frequencies. χ² > 3.841 (p < 0.05, df=1) → reject HWE.

Applications

GWAS quality control: SNPs out of HWE may indicate genotyping error. Carrier frequency estimation: q² = disease frequency → q = √(disease freq) → heterozygote carrier = 2pq. Detect selection: excess homozygotes or heterozygotes signal selection.

Glossary

Hardy-Weinberg Equilibrium (HWE)
p² + 2pq + q² = 1; genotype frequencies from allele frequencies under random mating; five conditions required; reached in one generation; null model for detecting evolution.
HWE Chi-Square Test
χ² = Σ(O−E)²/E; df = 1 for biallelic locus; χ² > 3.841 (p < 0.05) → reject HWE; GWAS QC excludes SNPs with HWE p < 0.001 in controls (likely genotyping error).
Wahlund Effect
Apparent excess homozygosity when multiple subpopulations with different allele frequencies are combined; produces false HWE violation; corrected by analyzing subpopulations separately.

Frequently Asked Questions

Hardy-Weinberg equilibrium (HWE) predicts the genotype frequencies expected in a population based solely on allele frequencies, assuming no evolutionary forces are acting. The formula: p² + 2pq + q² = 1. p = frequency of allele A; q = frequency of allele a; p + q = 1. Genotype frequencies: AA = p²; Aa = 2pq; aa = q². These frequencies are reached after one generation of random mating and remain stable indefinitely in the absence of selection, mutation, gene flow, or drift. HWE serves as a null model: observed genotype frequencies close to expected → no detectable evolution at this locus. Observed ≠ expected → some evolutionary force is acting.

For autosomal recessive diseases: if disease frequency = aa = q², then q = √(disease frequency); p = 1 − q; carrier frequency = 2pq. Examples: Cystic fibrosis: disease frequency ≈ 1/2,500 in Northern Europeans. q = √(1/2,500) = 1/50 = 0.02. p = 0.98. Carrier (Aa) = 2 × 0.98 × 0.02 ≈ 1/25. Approximately 1 in 25 Northern Europeans is a CF carrier. PKU: disease frequency ≈ 1/10,000. q = 1/100. Carrier = 2 × 0.99 × 0.01 ≈ 1/50. Limitation: HWE assumption of random mating; actual carrier frequencies may differ if population has substructure or high inbreeding.

Chi-square goodness-of-fit test: (1) From observed genotype counts, calculate allele frequencies: p = (2×n_AA + n_Aa) / 2N. (2) Calculate expected genotype counts: E_AA = N × p²; E_Aa = N × 2pq; E_aa = N × q². (3) χ² = (O_AA−E_AA)²/E_AA + (O_Aa−E_Aa)²/E_Aa + (O_aa−E_aa)²/E_aa. (4) df = 1 (for biallelic; 3 genotypes − 2 constraints = 1). (5) Compare to χ²₀.₀₅(1) = 3.841. In GWAS: SNPs that deviate from HWE (p < 0.001 in controls) are flagged as potential genotyping errors and excluded from analysis.

Excess homozygotes (deficit heterozygotes — HWE violation): Inbreeding: relatives mate → increases homozygosity above expectations → F_IS > 0. Population structure (Wahlund effect): mixing two populations with different allele frequencies → apparent excess homozygotes when combined. Genotyping errors: allele dropout causes heterozygotes to appear homozygous → common source of HWE failure in GWAS. Natural selection against heterozygotes (underdominance). Excess heterozygotes (excess over 2pq): heterozygote advantage (overdominance) → balancing selection (HbA/HbS in malaria-endemic populations). Recent admixture or bottleneck. Error in allele calling (adjacent SNPs in the same read called as one).