Allele Frequency Calculator: Formula and Examples
- Allele frequency
- %
- Result
- Copies of allele A
- 60 copies
- You entered
- Total allele copies
- 200 copies
- You entered
An allele frequency calculator finds the proportion of copies of a gene variant (an allele) among all copies of that gene in a population or sample. Enter the number of copies of the allele and the total number of allele copies; the calculator returns the frequency as a proportion and percentage.
Formula
Allele frequency = copies of the allele ÷ total copies of the gene in the sample. In symbols, f(A) = a / n, where a is the count of copies of allele A and n is the total count of copies at that gene locus. The percentage is 100 × f(A). Both counts are numbers of allele copies, not numbers of people.
For a diploid organism, each individual typically carries two copies of an autosomal gene, so a sample of 100 individuals has 200 allele copies, assuming all are included and the locus is present in both copies. For a haploid sample, each individual contributes one copy. Sex chromosomes and other loci with different copy numbers need to be counted according to the biological sample rather than automatically multiplying the number of individuals by two.
Worked Example
Using the calculator defaults, there are 60 copies of allele A among 200 total allele copies.
- Divide the allele count by the total: f(A) = 60 / 200 = 0.3.
- Convert the proportion to a percentage: 0.3 × 100 = 30%.
The allele frequency is therefore 0.3000, or 30.00%. The proportion is between 0 and 1; the percentage is the same result expressed on a 0-to-100 scale.
What Allele Frequency Means
An allele is one version of a DNA sequence at a particular genetic location, or locus. Allele frequency describes how common that version is among the copies of the locus being counted. It is a population-level measure, not the probability that a particular person has the allele, and it is not the same as genotype frequency.
For a gene with two alleles, A and a, their frequencies sum to 1 when every copy is classified as one of those two alleles: f(A) + f(a) = 1. If A has frequency 0.30, then a has frequency 0.70 in that two-allele dataset. At a locus with three or more alleles, the frequencies of all alleles sum to 1, subject to the same complete-counting assumption.
Genotype frequency instead counts individuals with each genotype. For example, an individual with genotype Aa has one A copy and one a copy. Counting people who are Aa does not directly give the frequency of A; allele copies must be tallied across the sample.
How to Count Allele Copies
For a diploid locus with two alleles, count the genotypes and translate them into copies. Suppose 50 individuals have genotypes AA, Aa, or aa, with counts of 18, 20, and 12 respectively. The sample has 100 allele copies in total. The number of A copies is 2 × 18 + 20 = 56, so f(A) = 56 / 100 = 0.56, or 56%.
- Each AA individual contributes two A copies.
- Each Aa individual contributes one A copy and one a copy.
- Each aa individual contributes zero A copies and two a copies.
This genotype-counting method is useful when genotype data are available but allele counts are not. If the dataset already gives allele-copy counts, use those directly. Do not divide the number of people with at least one A allele by the total number of people; that calculates a carrier proportion, which is a different quantity.
When to Use the Calculator
Use an allele frequency calculation when you have a clearly defined sample, locus, and allele count and want a simple descriptive estimate. Researchers may compare frequencies across populations or samples, while students use the calculation to connect genotype counts with population genetics. For the result to be interpretable, record which allele is being counted, how the sample was selected, and how missing or uncertain genotypes were treated.
The calculator performs arithmetic only. It does not determine whether a sample represents a broader population, test whether two frequencies differ meaningfully, or infer how a frequency arose. Sampling uncertainty matters: a frequency estimated from a small sample can differ from the underlying population frequency simply because only a limited number of copies were observed.
Common Counting Problems and Limits
- Using people as the denominator: For a diploid autosomal locus, the denominator is usually twice the number of individuals with usable data, not the number of individuals. Other ploidy or copy-number situations require the actual number of gene copies.
- Mixing up allele and genotype frequencies: Allele frequency counts copies; genotype frequency counts individuals in genotype categories.
- Ignoring missing data: If a person has no reliable genotype call at the locus, do not include their presumed copies in the denominator. Use the number of observed allele copies.
- Rounding too early: Keep the original counts and calculate the ratio before rounding. A displayed percentage rounded to two decimal places may not reproduce the exact count.
- Assuming a percentage is a personal probability: A 30% allele frequency does not by itself mean that 30% of individuals carry the allele. Genotype frequencies depend on how alleles are paired and on population conditions.
The calculation also assumes that the allele has been identified and counted consistently. At a locus with more than two variants, define the target allele precisely; the frequency of one allele is not necessarily the frequency of all variants grouped together. Comparing datasets may require harmonized allele labels, locus definitions, sampling methods, and treatment of related individuals or missing observations.
Frequently Asked Questions
How do you calculate allele frequency from genotype counts?
For a diploid locus, count two copies for each homozygote carrying the allele and one for each heterozygote carrying it. Divide that total by twice the number of individuals with valid genotype data.
Can allele frequency be greater than 1?
No. A valid allele frequency is from 0 to 1 inclusive, or 0% to 100%. A result outside that range usually means the allele count or total-copy denominator was entered incorrectly.
Do allele frequencies always add up to 100%?
Yes, for all mutually exclusive alleles at the same locus when every allele copy is counted and assigned. Frequencies for only a subset of alleles may add to less than 100%.
Is allele frequency the same as the percentage of people with a trait?
No. Allele frequency counts gene copies, while the percentage of people with a trait counts individuals. A trait may also depend on genotype, multiple genes, and environmental factors.
How does sample size affect an allele frequency estimate?
The calculation is exact for the copies observed in the sample, but a small or unrepresentative sample may estimate the wider population poorly. The calculator does not quantify that uncertainty.
Related
Formula used
in a | Copies of allele A | copies | 60 | 0 in n | Total allele copies | copies | 200 | 1 out f | Allele frequency | proportion | a / n | 4 out pct | Allele frequency | % | 100 * f | 2
Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work
Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.