Skip to content
OverCalculator
  1. Home
  2. Biology
  3. Allele Frequency Calculator
Biology

Allele Frequency Calculator

Estimate Hardy-Weinberg allele frequency and carrier frequency from recessive disease frequency, with assumptions, interpretation, and a worked example.

Published

Carrier frequency
Carrier frequency
0.0392
1:26
Healthy allele frequency (p)
0.9800
Mutant allele frequency (q)
0.0200
Carrier ratio
1:26

Uses Hardy-Weinberg logic from the original calculator: q = √disease frequency, p = 1 − q, carriers = 2pq.

Enter the frequency of the disease in decimal form. For example, if the disease affects 1 in 2500 people, enter 0.0004.

Results update as you type.

Allele Frequency Calculator

A small disease frequency can hide a much larger carrier pool. This allele frequency calculator uses Hardy-Weinberg reasoning to turn an affected recessive disease frequency into the allele frequencies p and q, the expected carrier frequency 2pq, and a rounded carrier ratio. It is built for population-genetics learning and rough screening context, not for personal genetic counseling.

What it measures

The calculator assumes a two-allele recessive model. The disease frequency you enter is treated as the affected homozygote frequency, traditionally written as q squared. From that single number, the calculator estimates the disease-associated allele frequency q, the other allele frequency p, and the expected heterozygote carrier frequency. This is the classic Hardy-Weinberg shortcut used when an autosomal recessive condition is rare enough that affected frequency is easier to observe than carrier frequency.

For decimal practice, the percentage calculator can help convert between percent, fraction, and decimal inputs. If you are comparing this with other growth or compounding models, see the compound growth calculator and the bacteria growth calculator. For concentration-style genetics lab work, the molarity calculator may be useful, but it answers a different question.

Formula used by the calculator

The Hardy-Weinberg model for two alleles is:

p+q=1p + q = 1

p2+2pq+q2=1p^{2} + 2pq + q^{2} = 1

This calculator starts with disease frequency as q squared:

q=disease frequencyq = \sqrt{\text{disease frequency}}

Then it calculates the other allele frequency:

p=1qp = 1 - q

Finally, it calculates the expected carrier frequency:

carrier frequency=2×p×q\text{carrier frequency} = 2 \times p \times q

The carrier ratio shown in the result hint is not a separate biological calculation. The 1:N ratio is one divided by carrier frequency, rounded to the nearest whole number.

Example: calculating allele frequency

Use the default disease frequency, 0.0004. That corresponds to 1 affected individual per 2,500 in the model.

q=0.0004=0.0200q = \sqrt{0.0004} = 0.0200

p=10.0200=0.9800p = 1 - 0.0200 = 0.9800

carrier frequency=2×0.9800×0.0200=0.0392\text{carrier frequency} = 2 \times 0.9800 \times 0.0200 = 0.0392

The calculator displays carrier frequency as 0.0392. For the carrier ratio, it computes one divided by 0.0392, which is about 25.51, and rounds to 26. The hint therefore reads 1:26. In plain language, the model predicts about 3.92 percent carriers, or roughly 1 carrier in 26 people, under the stated assumptions.

Interpretation and assumptions

Carrier frequency is not disease frequency. Disease frequency in this page is q squared, while carrier frequency is 2pq. For rare recessive conditions, carriers can be much more common than affected people because only one disease-associated allele is needed to be a carrier, but two are needed to be affected in the simplified model.

Hardy-Weinberg equilibrium is a null model. It assumes a large population with random mating and no meaningful selection, mutation, migration, or drift for the allele being considered. Human populations can violate those assumptions through ancestry structure, founder effects, consanguinity, differential survival, and changing reproductive patterns. That does not make the calculation useless; it means the output should be read as an estimate conditional on the model.

Reading the affected-frequency input

The hardest part of using this calculator is often not the algebra; it is deciding whether the input really belongs in the q-squared position. A registry prevalence, a newborn-screening rate, and a published incidence can describe different things depending on survival, ascertainment, diagnostic criteria, and age. For a recessive Hardy-Weinberg estimate, the cleanest input is the fraction of people in the population who are affected because they carry two disease-associated alleles for the same condition. If the source reports one case per N people, enter one divided by N. If it reports a percent, divide by 100 before entering it.

The calculator also does not accept genotype counts directly. When you have counts of AA, Aa, and aa individuals, allele frequency should be computed from allele counts instead: count two alleles for each homozygote and one for each heterozygote, then divide by twice the number of individuals. That is a different workflow from the disease-frequency shortcut used here.

Limitations and common mistakes

Do not enter a percentage without converting it. A disease frequency of 0.04 means 4 percent, not 1 in 4,000. Do not use this calculator for dominant conditions, X-linked inheritance, multiallelic disorders, incomplete penetrance, or conditions where affected frequency is not well represented by q squared. Also avoid mixing population data: using a disease frequency from one ancestry group to discuss another can be misleading.

At the upper endpoint, a disease frequency of 1 gives q = 1, p = 0, and a carrier frequency of 0. Because a reciprocal carrier ratio is undefined there, the result reports that the model has no heterozygous carriers rather than displaying an infinite ratio.

Sources

Frequently asked questions

What input does the allele frequency calculator use?
It uses disease frequency entered as a decimal, assuming the disease is recessive and the affected frequency equals q squared. For example, 1 affected person in 2,500 is entered as 0.0004. The calculator then estimates q, p, carrier frequency, and a rounded carrier ratio.
What is carrier frequency in Hardy-Weinberg terms?
Carrier frequency is the expected heterozygote frequency, written as 2pq in a two-allele recessive model. Carriers have one normal allele and one disease-associated allele. They are counted separately from affected homozygotes, whose expected frequency is q squared in this simplified population model.
When is the Hardy-Weinberg estimate reasonable?
It is a useful approximation for a large, randomly mating population when mutation, migration, selection, nonrandom mating, and genetic drift are not strongly changing the allele. Real human populations often depart from those assumptions, so the result should be treated as a model-based estimate.
Can this calculator diagnose genetic risk for a person?
No. It estimates population-level frequencies from a simplified recessive model. Individual risk depends on ancestry, family history, testing method, penetrance, variant classification, partner genotype, and many clinical details. Genetic counseling or clinical testing is needed for personal medical decisions.
Why does the carrier ratio round to a whole number?
The 1 to N ratio is one divided by carrier frequency, rounded to the nearest whole number. That makes communication easier for readers, but the decimal carrier frequency is the more precise output.
What happens if the disease frequency is very high?
The equations remain defined through a disease frequency of 1, but the model becomes less realistic near that endpoint. At exactly 1, q equals 1, p equals 0, and carrier frequency equals 0, so the result states that there are no heterozygous carriers under this model.

Related calculators

Allele Frequency Calculator updated at