Tutorials › Statistical Genetics › Strand, Reference Alleles, and Allele-Coding Errors

Genotyping Data and Quality Control · Tutorial 86 of 989

Strand, Reference Alleles, and Allele-Coding Errors

You will learn a careful workflow for checking strand orientation, reference alleles, and allele labels before combining or interpreting genotype data.

Beginner 10 min read

What You'll Learn

  • Apply base complementation to compare SNP allele pairs across strand orientations
  • Explain why A/T and C/G variants are ambiguous from allele pairs alone
  • Check a reported reference allele against the correct genome build and position
  • Distinguish a strand flip from a REF/ALT label swap
  • Translate genotype dosage when the counted allele changes
  • Identify when a mismatch requires verification rather than an automatic correction

Why Allele Labels Need Careful Checking

A genotype file can contain valid-looking genotypes and still describe alleles differently from another file. One file may report a variant on the forward strand and another on the opposite strand; two records may use different reference genome builds; or REF and ALT labels may have been exchanged. These issues matter when genotype data are combined, because the same allele can be represented by different letters, and a dosage may count different alleles in different files.

The key is to treat allele harmonization as a sequence of checks, not as a guess based on one matching label. First compare the variant identity and genome build, then compare allele pairs under possible strand complementation, and finally verify which allele is REF, ALT, or the allele counted in a dosage. A match can support a representation change, but it does not by itself prove that two records refer to the same variant.

Definition: For a single-nucleotide variant (SNP), the allele pair is the unordered pair of nucleotides observed or reported at that locus, such as \(\{A,G\}\). The reference allele (REF) is the nucleotide specified by a particular reference genome assembly at the stated position; the other reported allele is commonly called the alternate allele (ALT). A strand flip represents the same locus using the complementary DNA strand, where \(A\leftrightarrow T\) and \(C\leftrightarrow G\). A REF/ALT swap exchanges which allele is labelled reference and which alternate; it is not, by itself, a strand flip.

Complementing Alleles and Comparing Pairs

DNA strands are complementary: adenine pairs with thymine, and cytosine pairs with guanine. Define the complement map \(c\) by \(c(A)=T\), \(c(T)=A\), \(c(C)=G\), and \(c(G)=C\). For a SNP with allele pair \(\{a_1,a_2\}\), its complementary pair is \(\{c(a_1),c(a_2)\}\). Since the pair is unordered, the order of the two alleles does not affect the comparison.

$$ c(\{a_1,a_2\})=\{c(a_1),c(a_2)\}, \qquad c(c(a))=a $$

For example, the complement of \(\{A,G\}\) is \(\{T,C\}\), which is the same unordered pair as \(\{C,T\}\). Thus \(\{A,G\}\) and \(\{C,T\}\) are compatible with opposite-strand representations. This compatibility is evidence to investigate, not proof that the records identify the same variant: the chromosome, coordinate, genome build, and reference allele still need to agree appropriately.

Some pairs cannot be distinguished by complementing. The complement of \(\{A,T\}\) is \(\{T,A\}=\{A,T\}\); similarly, the complement of \(\{C,G\}\) is \(\{G,C\}=\{C,G\}\). These are called palindromic allele pairs. Their unordered pair remains unchanged after a strand flip, so the pair alone cannot establish orientation.

Worked Example: Comparing a Nonpalindromic Pair

Suppose a hypothetical source file reports a SNP as REF \(A\), ALT \(G\) at a specified chromosome and position. A second file for the same stated build and position reports REF \(T\), ALT \(C\). Are the pairs compatible with a strand flip, and does the reference labeling agree?

Step 1: Compare the allele pairs. The source pair is \(\{A,G\}\). Complement each allele:

$$ c(\{A,G\})=\{c(A),c(G)\}=\{T,C\}=\{C,T\} $$

The second file's pair is \(\{T,C\}\), so its pair is compatible with the complement of the source pair.

Step 2: Check the REF labels. The source REF \(A\) complements to \(T\), and the second file reports REF \(T\). The source ALT \(G\) complements to \(C\), which matches the second file's ALT \(C\). Thus both allele labels are consistent with a strand flip, assuming the records truly refer to the same variant and the stated build and position are correct.

The conclusion is limited: the representation is internally compatible with a strand flip. The pair comparison does not independently establish variant identity, so the coordinate and build must still be checked.

Reference Alleles and Genome Builds

A REF label has meaning only relative to a specified reference genome assembly and position. The same biological region can have different coordinates in different builds, and a record compared at the wrong build or coordinate can appear to have the wrong reference allele. Before treating a REF mismatch as a strand issue, verify the chromosome, position, build, and variant identity. If records have undergone allele normalization, compare them in a consistent representation; normalization can affect variant coordinates and allele strings, especially for indels.

At a correctly matched SNP coordinate and build, the reported REF should match the base in that reference sequence when the record is expressed in the same orientation. If the data are on the opposite strand, the corresponding reference base must be complemented as well. A matching unordered allele pair does not establish that the REF and ALT labels are correctly oriented.

Worked Example: A Pair Mismatch That Does Not Support a Strand Flip

At a hypothetical locus, a trusted record for a specified build reports the allele pair \(\{C,G\}\). Another file for a purportedly matching locus reports \(\{T,A\}\). Determine whether the pair comparison supports a strand-flip explanation.

Complement the trusted pair:

$$ c(\{C,G\})=\{c(C),c(G)\}=\{G,C\}=\{C,G\} $$

The complementary pair is still \(\{C,G\}\), not \(\{T,A\}\). Therefore, the reported T/A pair is not the complement of C/G, so this allele-pair comparison does not support a strand-flip explanation. The failed REF check still requires verification of the build, position, and variant identity.

Do not repair the mismatch by changing letters simply because a strand flip is possible in general. First check whether the two records are at the same locus on the same build and whether either record has a labeling or data-import error. If those checks do not resolve the discrepancy, the records should remain flagged as unresolved rather than being harmonized by assumption.

Palindromic Pairs and the Limits of Allele-Pair Checks

For A/T and C/G variants, comparing the allele pair cannot distinguish the two strand orientations. For instance, a reported A/T pair is compatible with either orientation because complementing it gives the same unordered pair. A/T and C/G are both palindromic in this sense; neither is inherently more resolvable from the pair itself.

A reference allele and a verified build can provide an additional check: the reference base at the correctly identified coordinate constrains which allele should be REF in that representation. However, if the build, coordinate, or orientation is uncertain, the reference check cannot be treated as settled. In particular, seeing the same A/T pair in two files is not evidence that their strands agree. Mark the orientation as unresolved until other reliable information establishes it; do not infer orientation from the pair alone.

Worked Example: An A/T Pair With Unresolved Orientation

Two hypothetical files report the same stated chromosome and position, with allele pair A/T. File 1 labels A as REF and T as ALT. File 2 labels T as REF and A as ALT. What can the allele-pair comparison establish?

The pair in File 1 complements as follows:

$$ c(\{A,T\})=\{T,A\}=\{A,T\} $$

Therefore, the pair in File 2 is compatible with the same strand orientation and also with the opposite strand orientation. The fact that File 2's REF is T rather than A could reflect a REF/ALT swap, a representation on the opposite strand, a build or coordinate problem, or another record-level discrepancy. The pair alone cannot choose among these explanations.

The next check is to verify the build and position and compare the reported REF to the reference base in that assembly, taking orientation into account. Until that check resolves the labels, it is not justified to call this either a confirmed strand flip or a confirmed REF/ALT swap.

Swapped Allele Labels and Dosage Coding

A strand flip changes the nucleotide letters used to represent alleles; a REF/ALT swap changes the labels assigned to the two alleles. These events can occur separately or together. Also, a dosage is not necessarily a count of REF or ALT: it counts whichever allele the file's coding convention specifies. The counted allele must therefore be identified before comparing dosages or interpreting an effect estimate.

For a diploid genotype, suppose dosage \(d\) counts copies of allele \(A\), so \(d\) can be \(0\), \(1\), or \(2\). If the same genotypes are recoded to count the other allele \(G\), each person has two allele copies and the new dosage is \(d'=2-d\). The homozygote dosages exchange, while the heterozygote remains 1:

$$ \begin{array}{c|ccc} \text{Genotype} & AA & AG & GG\\ \hline \text{Copies of }A & 2 & 1 & 0\\ \text{Copies of }G & 0 & 1 & 2 \end{array} \qquad d'=2-d $$

This identity follows because each diploid genotype contains two copies in total: if \(d\) copies are \(A\), then \(2-d\) copies are \(G\). Consequently, a dosage change caused by counting the other allele is not a biological change in genotype. It is a coding change that must be documented and accounted for.

Worked Example: Detecting a Dosage-Allele Change

A hypothetical file lists genotypes \(AA, AG, GG, AG\) and states that dosage counts allele \(A\). A second file lists the same genotypes but states that dosage counts allele \(G\). Calculate both dosage vectors and verify the conversion.

For the first file, the copies of \(A\) are \(2,1,0,1\), so its dosage vector is \((2,1,0,1)\). The copies of \(G\) are \(0,1,2,1\), so the second dosage vector is \((0,1,2,1)\). Applying the conversion to each first-file dosage gives:

$$ (2-d)=(2-2,\;2-1,\;2-0,\;2-1)=(0,1,2,1) $$

The vectors agree. If the files instead describe REF and ALT differently, that fact alone does not tell us which dosage allele was counted: the coding statement must be checked explicitly. Likewise, a strand complement changes letters but does not change which physical allele copies an individual carries.

A Practical Harmonization Sequence

Use a documented sequence of checks for each SNP being compared. A convenient order is to verify identity and build before deciding whether allele labels can be reconciled. If any step produces an unresolved contradiction, retain a flag for review rather than forcing the records to match.

1
Verify the locus.
Check chromosome, position, genome build, and variant identity. Do not assume that a shared identifier alone guarantees equivalent records.
2
Compare allele pairs.
Compare the unordered pairs directly and after complementing both alleles. A complementary match supports an opposite-strand representation for a nonpalindromic pair.
3
Check REF against the build.
At the verified coordinate, check the reference base in the stated orientation. A pair match does not guarantee that REF and ALT are correctly assigned.
4
Resolve allele coding.
Record which allele each dosage counts and translate dosage if the counted allele changes. Treat A/T and C/G orientation as unresolved when the pair and reference information do not determine it.

Common Mistakes and Why This Check Matters

  • Assuming every mismatch is a strand flip. Complementation has a specific mapping. Check the actual pair; for example, the complement of C/G is C/G, not T/A.
  • Treating a matching pair as proof of matching records. Different variants can have the same pair, and a build or coordinate mismatch can invalidate the comparison. Verify locus identity and build.
  • Assuming A/T or C/G pairs reveal orientation. Each pair is unchanged as an unordered pair by complementation. Pair comparison alone leaves orientation ambiguous.
  • Equating REF/ALT labels with dosage coding. A dosage may count an explicitly designated allele; read that coding definition rather than inferring it from the REF/ALT fields.
  • Silently changing a dosage. If the counted allele changes in a diploid genotype, use \(d'=2-d\) and record the transformation. Do not interpret the recoded number as a different genotype.

These checks prevent allele-label inconsistencies from being mistaken for biological differences. They are especially important when data from different sources are combined or when an effect is tied to a named allele. A record with unresolved strand orientation or a failed reference check should be treated as unresolved, not harmonized by guesswork.

Check Your Understanding

Answer each question by stating what the allele comparison establishes and what still needs checking.

  1. What is the complementary unordered pair for \(\{A,C\}\), and why is a matching complementary pair not sufficient to prove variant identity?
  2. Why can the pair \(\{C,G\}\) not, by itself, distinguish the two strand orientations?
  3. A record reports T/A where a verified comparison record has C/G. Does that pair comparison support a strand flip? What should be checked next?
  4. If a diploid dosage \(d\) counts one allele, derive the dosage for the other allele and give the new dosage when \(d=0.7\) is not allowed as a single-person genotype code. What does this indicate about the scale being used?
  5. Two files have the same A/T pair but opposite REF labels. Name two checks needed before deciding whether this is an orientation issue or a label swap.
Clinical Biostats