Why Filter Imputed Variants?
Imputation produces genotype estimates for variants that were not directly observed, but those estimates are not equally reliable. A variant-level filter is a rule for deciding which variants to keep for a stated analysis and which to exclude. The decision should use information about both imputation quality and allele frequency: these characteristics are related in many data sets, but they answer different questions.
Quality metrics summarize uncertainty or estimated accuracy of imputed genotypes. Allele frequency describes how common an allele is in the analyzed sample or population. A variant can be common but poorly imputed, or rare but well imputed according to a quality metric. Neither a high quality score nor a particular frequency alone establishes that the variant is suitable for every analysis.
This tutorial assumes that variants have been aligned and that the quality metric and allele-frequency estimate refer to the same variant representation and analyzed sample set. In the earlier material on imputation quality metrics, dosage \(R^2\), and INFO scores, these measures were introduced as estimates of imputation quality. Here the emphasis is how to use such measures in a filter, not how to derive them. Their exact definitions can differ among software formats, so use a consistent metric and record its source.
Writing a Filter Precisely
Let \(Q_j\) denote the selected imputation quality metric for variant \(j\), and let \(M_j\) denote its minor-allele frequency. A simple joint rule retains variant \(j\) if both cutoffs are met:
The quality and frequency conditions are joined by “and.” A variant that passes one condition but fails the other is excluded under this rule. Equality passes when the rule uses “at least”; a value just below the cutoff fails. These details should be stated rather than left to an ambiguous phrase such as “filter on quality.”
For diploid samples, a dosage \(D_{ij}\) is the expected number of copies, from 0 to 2, of a specified allele for individual \(i\) at variant \(j\). With \(n\) individuals and no missing dosages, an estimated frequency of that allele is
The dosage-based estimate uses fractional expected allele counts; it need not equal the frequency obtained by converting each dosage to a hard genotype call. State which estimate is used, especially for low-frequency variants where a small change in estimated frequency can cross a cutoff. If the analyzed sample set, ploidy, or missing-data handling differs from the diploid complete-data assumption above, the frequency calculation must be adapted accordingly.
Worked Examples: Applying and Comparing Cutoffs
Worked Example: Strict and Relaxed Joint Filters
Suppose five hypothetical imputed variants have the following metrics. Quality is reported on a scale from 0 to 1, with larger values indicating better estimated imputation quality. The listed MAF values are proportions.
| Variant | Quality score | MAF |
|---|---|---|
| v1 | 0.98 | 0.120 |
| v2 | 0.91 | 0.010 |
| v3 | 0.68 | 0.003 |
| v4 | 0.75 | 0.180 |
| v5 | 0.84 | 0.004 |
First apply the strict rule \(Q_j\geq0.90\) and \(M_j\geq0.01\). For v1, \(0.98\geq0.90\) and \(0.120\geq0.01\), so it passes. For v2, \(0.91\geq0.90\) and \(0.010=0.01\), so it also passes because equality qualifies. Variant v3 fails both conditions: \(0.68<0.90\) and \(0.003<0.01\). Variant v4 passes the frequency condition but fails quality, since \(0.75<0.90\). Variant v5 fails both, since \(0.84<0.90\) and \(0.004<0.01\). The strict retained set is therefore \(\{v1,v2\}\).
Now use the less stringent rule \(Q_j\geq0.80\) and \(M_j\geq0.001\). Variants v1, v2, and v5 pass both conditions. Variant v3 meets the frequency cutoff but fails quality because \(0.68<0.80\); v4 also fails quality because \(0.75<0.80\). The relaxed retained set is \(\{v1,v2,v5\}\). Relative to the strict rule, only v5 is added. It would be incorrect to say that v3 is added: its quality score is below even the relaxed quality cutoff.
Worked Example: Estimating MAF From Dosages
Consider a hypothetical diploid sample of \(n=100\) individuals at one variant. Of the 100 dosages for the allele of interest, 94 are 0, four are 0.10, and two are 0.40. These are expected allele counts, not hard genotype calls. Their sum is
The dosage-based allele-frequency estimate is \(\hat{p}=1.20/(2\times100)=1.20/200=0.006\). Since this is below one half, \(M=0.006\). Suppose this variant has quality score \(Q=0.86\). Under the rule \(Q\geq0.80\) and \(M\geq0.005\), it passes both conditions: \(0.86\geq0.80\) and \(0.006\geq0.005\). Under a rule with the same quality cutoff but \(M\geq0.01\), it fails the frequency condition because \(0.006<0.01\). The different decision follows from the frequency cutoff, not from a change in its imputation quality.
The calculation also shows why a dosage-based frequency should not be described as an observed count of minor-allele copies. The sum of dosages is an expected count, and the estimated frequency is the corresponding expected proportion among the \(2n\) diploid allele copies.
Worked Example: Matching a Filter to an Analysis Goal
Suppose a hypothetical analysis team is preparing two separate variant sets. One set is for a common-variant analysis and uses \(Q\geq0.80\), \(M\geq0.01\). The other is for a low-frequency-variant analysis and uses \(Q\geq0.90\), \(M<0.01\). The team reports four variants:
| Variant | Quality score | MAF |
|---|---|---|
| a | 0.92 | 0.040 |
| b | 0.96 | 0.006 |
| c | 0.84 | 0.008 |
| d | 0.70 | 0.200 |
For the common-variant set, a passes because \(0.92\geq0.80\) and \(0.040\geq0.01\). Variant b fails because its MAF is below 0.01, and c fails for the same reason despite passing the quality cutoff. Variant d meets the frequency condition but fails quality because \(0.70<0.80\). The common-variant set is \(\{a\}\).
For the low-frequency set, b passes because \(0.96\geq0.90\) and \(0.006<0.01\). Variant c is below the frequency cutoff but fails the quality condition, since \(0.84<0.90\). Variants a and d do not meet the low-frequency condition. Thus the low-frequency set is \(\{b\}\). These examples illustrate how a stated goal can change the frequency rule, while the quality rule still excludes variants that do not meet its own criterion. The cutoffs are hypothetical choices, not universal recommendations.
Why Thresholds Need Context
A single cutoff is convenient and reproducible, but no threshold is correct for every data set or scientific question. A stricter quality cutoff usually removes more variants and can reduce uncertainty in the retained set; it can also remove many low-frequency variants, for which quality estimates may be less stable. A permissive cutoff retains more variants, but does not make the less reliable genotypes more accurate. The trade-off should be described rather than hidden behind a claim that one threshold is simply “best.”
Frequency cutoffs also depend on the intended analysis and population. A minimum MAF of 0.01 deliberately excludes variants below one percent in the analyzed sample; that may be unsuitable when the aim is to study low-frequency variants. Conversely, lowering the frequency cutoff does not itself establish that rare variants are accurately imputed. Sample-wide MAF can also obscure differences among ancestry groups: a variant rare overall might be more frequent in one subgroup, or vice versa. If the scientific question concerns particular groups, inspect frequencies in those groups rather than assuming a pooled estimate captures all relevant patterns.
A filter should name its metric, its threshold, how MAF was estimated, the sample set used for that estimate, and the boundary convention. If several quality metrics are available, do not silently treat their numerical values as interchangeable. Scores on similar scales can have different definitions and calibration. Use one consistently for the stated rule, or define explicitly how multiple metrics combine.
Diagnostics, Alternatives, and Limitations
Before finalizing a filter, compare the retained and excluded variants and inspect how filtering changes the set. Useful checks include the number retained at each step; distributions of quality and MAF before and after filtering; and counts near each cutoff. A sudden loss of many variants at one threshold may be intended, but it should be visible and explainable. Check that the metric and MAF values are present and correctly matched to variant identifiers. Missing or invalid values need an explicit policy; silently treating missing quality as a high score is not defensible.
Also examine whether exclusion is concentrated among low-frequency variants, genomic regions, or ancestry groups relevant to the analysis. A global threshold can create an uneven retained set. Such patterns do not automatically prove a filter is wrong, but they can reveal that a nominally neutral cutoff has consequences for the scientific target. Record counts and reasons for exclusion so that the result can be reproduced and reviewed.
A hard threshold is the main operational alternative to retaining every imputed variant: it is simple to implement and yields a clearly defined set. Other reasonable approaches include reporting results for multiple prespecified threshold choices or applying different frequency criteria to analyses with different aims. Comparing retained sets makes threshold sensitivity apparent. These approaches do not remove the need to justify thresholds; they make the consequences easier to assess. Avoid choosing cutoffs after inspecting which variants produce favorable findings, since that makes the selection outcome-dependent.
Filtering has limits. A quality score is an estimate, not a guarantee of correct genotype probabilities at every variant or in every subgroup. A frequency estimate depends on the sample and on how dosages are summarized. Passing a filter does not prove that a variant is suitable for a particular downstream model; it only establishes that it met the stated rules. Likewise, failure to pass does not show that the biological variant is unimportant. Filtering is a data-quality and analysis-design decision, not a biological interpretation.
A Short Justification for Nested Retained Sets
The effect of changing cutoffs can be shown directly. Let \(R(q,f)\) be the set of variants for which \(Q_j\geq q\) and \(M_j\geq f\). If both cutoffs are relaxed to \(q'\leq q\) and \(f'\leq f\), then every variant in \(R(q,f)\) also satisfies the relaxed conditions: \(Q_j\geq q\geq q'\) and \(M_j\geq f\geq f'\). Therefore,
This proves that simultaneously lowering both minimum cutoffs cannot remove a variant that previously passed. It may add variants, as v5 was added in the first example. The inclusion need not hold if one cutoff is tightened while the other is relaxed; in that case, compare the rules variant by variant rather than assuming one retained set contains the other.
Common Pitfalls
- Applying an “or” when the rule says “and.” Passing quality alone is not enough under a joint filter. Check both inequalities for every variant.
- Rounding before checking a boundary. A reported MAF of 0.01 may conceal a value slightly below 0.01. Apply the rule to the recorded precision and report enough digits to make borderline decisions interpretable.
- Assuming a relaxed frequency cutoff rescues poor quality. In the first example, v3 has MAF 0.003 but quality 0.68; it fails the relaxed quality cutoff of 0.80.
- Calling a cutoff universally optimal. Thresholds depend on the metric, the sample, and the analysis goal. State and justify the rule rather than presenting a convention as a law.
- Confusing retention with validation. Passing the chosen filters means only that the variant meets those rules; it is not proof of imputation accuracy in every setting.
Check Your Understanding
Answer each question, then compare with the brief solutions below.
- A variant has quality 0.83 and MAF 0.009. Does it pass the rule \(Q\geq0.80\) and \(M\geq0.01\)?
- For \(n=50\) diploid individuals, the sum of dosages for one allele is 0.80. Calculate its estimated frequency and MAF, assuming that allele is the minor allele.
- Under a rule \(Q\geq0.90\), \(M\geq0.001\), does a variant with quality 0.89 and MAF 0.020 pass? Explain.
- Both minimum cutoffs are lowered. Can the new retained set exclude a variant that passed the old rule? State the condition needed for your answer.
Solutions. (1) No. Quality passes, \(0.83\geq0.80\), but MAF fails, \(0.009<0.01\); both conditions are required. (2) \(\hat{p}=0.80/(2\times50)=0.80/100=0.008\), so the MAF is 0.008 under the stated assumption. (3) No. The MAF passes, but \(0.89<0.90\), so quality fails. (4) No, provided both cutoffs are lowered or left unchanged and the same metrics and data are used. A variant that met the old inequalities must still meet the weaker inequalities.