Sample Swaps and Identity QC: Why the Cleanest VCF in Your Batch Can Belong to the Wrong Person

Sample Swaps and Identity QC: Why the Cleanest VCF in Your Batch Can Belong to the Wrong Person — Zetobit
Zetobit Bioinformatics Insight Series
BIOINFORMATICS INSIGHT SERIES Sample Swaps & Identity QC Why the cleanest VCF in your batch can belong to the wrong person TUMOR NORMAL not the same person both VCFs pass every technical QC — the swap is silent Kanna Nandakumar, PhD · Zetobit

Sample Identity & Data Integrity

Sample Swaps and Identity QC: Why the Cleanest VCF in Your Batch Can Belong to the Wrong Person

A mislabeled tube, a pipetting error, a transposed row on a plate — and a sample produces a flawless VCF that belongs to someone else, or to two people at once. Every technical metric passes, because technically nothing failed. The only way to catch it is to ask the genome who it belongs to.

Every quality-control dashboard in a sequencing pipeline is built to answer one question: did the sequencing work? Read quality, mapping rate, duplication rate, coverage uniformity, transition/transversion ratio — all of them measure whether the machine produced good data. None of them measures whether the good data came from the sample on the label. That second question is entirely orthogonal to the first, and a sample swap is the case where the sequencing works perfectly and the answer is still wrong.

This is a different species of failure from most of what this series has covered. There is no assumption violated, no edge case in an algorithm, no detection limit. A swapped sample yields a VCF that is internally consistent, well-formed, and high-quality in every technical sense. It simply describes the wrong human. And because nothing errored, the mistake propagates silently into the analysis, the report, and — in a clinical setting — potentially the treatment decision.

Why standard QC is structurally blind to it

The reason conventional metrics cannot catch a swap is that they are all intra-sample measurements: they assess a file against expectations of what good data looks like, not against the identity it is supposed to have. A VCF from patient B, run under patient A’s label, has a perfectly normal Ts/Tv ratio, normal coverage, normal everything. The corruption is in the metadata-to-biology mapping, which no read-level statistic can see.

Catching it requires an inter-sample comparison against genetic identity — and the tool for that is a genetic fingerprint. Because common SNPs are inherited and stable across every tissue in a person, a small panel of them acts as a barcode. Identity tools genotype a curated set of very common SNPs — minor allele frequency roughly between 0.1 and 0.9 — chosen to be informative, and use the resulting genotype profile to verify sample identity, detect swaps, and check sex concordance.1 Two aliquots of the same person match at essentially every fingerprint SNP; two different people diverge at a predictable fraction. The genome carries its own label, and reading it is the only check that is immune to a mislabeled tube.

genotype at shared fingerprint SNPs → pair A AA AG GG AA GG AG AA GG AA AG GG AA GG AG AA GG ~100% → same person pair B AA AG GG AA GG AG AA GG GG AA GG AG AA GG AG AA ~50% → a swap contam. AA AG GG AG GG AG AA AG excess heterozygous calls where homozygous expected mixture → contamination
Identity is an inter-sample question. Reducing each sample to its genotype at a shared SNP panel turns identity into arithmetic: a matched pair agrees at nearly every site, a swap agrees at roughly the rate expected for two random people, and cross-individual contamination shows up as a sprinkle of unexpected heterozygous calls where a clean sample would be homozygous. None of this is visible in read-level QC.

Tumor–normal work raises the stakes twice

Matched tumor–normal sequencing — the standard design in cancer genomics — is where identity failures do the most damage, for a specific reason. The whole point of sequencing a matched normal is to subtract the patient’s germline variants so that what remains is somatic: the mutations the tumor acquired. That subtraction only works if the tumor and the normal come from the same person. If they don’t — a swap — the germline variants of two different people fail to cancel, and the caller reports a flood of the patient’s own inherited variants as somatic mutations. A confident, entirely false somatic profile.

Contamination is the subtler cousin of the swap, and tumor–normal analysis is acutely sensitive to it. Even very low levels of cross-sample contamination significantly impact somatic mutation calling, because contaminant germline variants can be incorrectly interpreted as somatic — so detecting swaps and low-level contamination is a critical step that should precede every somatic analysis.2 The problem is compounded by biology: estimating contamination in tumors is confounded by the frequent copy-number alterations that distort allelic-ratio distributions, which is exactly what makes generic contamination estimators struggle on tumor data.2 Purpose-built tools rise to it — Conpair was shown to measure contamination as low as 0.1% even in the presence of copy-number changes, and its contamination estimates correlated strongly with tumor–normal concordance and with the number of germline variants miscalled as somatic by widely used callers.23 That correlation is the whole argument in one sentence: identity failure and false somatic calls are the same phenomenon measured two ways.

A tumor–normal swap does not produce a subtly wrong answer. It produces a spectacularly wrong one — the patient’s entire germline reclassified as tumor mutations — while every read-level metric stays green. This is the failure mode most worth an explicit, non-optional guardrail, because its blast radius is the entire somatic callset.

The concordance check, and where it gets subtle

Operationally, the check reduces to a concordance score: genotype both samples at the fingerprint panel and measure agreement. A matched pair scores near the top of the range; a swap scores near the level of two unrelated people. Large projects bake a threshold into their pipelines — in the Conpair analysis, samples were excluded for quality issues including matched tumor–normal genotype concordance below 60%.3 But the tumor context adds a real subtlety that a naive concordance cutoff can trip over: a tumor genome is not a clean copy of the germline. Somatic mutations, and especially loss of heterozygosity, change genotype calls at some sites. SNP concordance is excellent between blood and normal tissue but slightly lower between blood and tumor, precisely because of somatic mutation and the extensive loss of heterozygosity tumors carry.4 A good identity check therefore has to distinguish “same person, but one sample is a tumor” from “different people” — which is why tools designed for cancer data model that difference rather than applying a flat germline-style threshold.

A further refinement handles the case where you have no obvious pair to compare against. Methods based on linkage disequilibrium can detect swaps across diverse NGS data types — DNA, RNA, and across assays — by exploiting the correlation structure among nearby SNPs, which lets identity be verified even between data types that don’t share a straightforward genotype representation.1 The tooling landscape now includes several mature options — NGSCheckMate, Picard’s CrosscheckFingerprints, Conpair, Somalier, and VerifyBamID/ContEst for contamination — each tuned to somewhat different inputs and use cases.3

What a real identity-QC step looks like

The unifying principle is simple: identity is a first-class QC axis, separate from technical quality, and it has to be checked explicitly because nothing else will surface it. Concretely:

  • Fingerprint every sample and compare within each expected group. Confirm that replicates, and tumor–normal pairs, actually match at a common-SNP panel — and that samples from different patients do not.1
  • Run contamination estimation before somatic calling, not after. Cross-individual contamination inflates false somatic calls, so it belongs upstream of the caller; use a tumor-aware estimator that tolerates copy-number changes.2
  • Check inferred sex against reported sex. A mismatch between genetic and recorded sex is a cheap, high-value tripwire for a mislabeled sample.1
  • Use tumor-aware concordance thresholds. Expect somewhat lower tumor–normal concordance from somatic mutation and loss of heterozygosity, and don’t mistake that for a swap — or a real swap for tumor biology.4
  • Verify identity across data types when you integrate them. If DNA and RNA from “the same” sample are combined, confirm it genetically; LD-based methods make this possible across assays.1

Most of this series is about methods that can quietly return a wrong answer because an assumption failed. Sample identity is the case where nothing failed — the data is pristine, the pipeline is green, and the result is still attached to the wrong person. That is exactly why it needs its own deliberate check. The genome is the one label that cannot be mislabeled; identity QC is simply the discipline of reading it before trusting anything downstream.

References

  1. NGSTroubleFinder: a tool for detection and quantification of contamination and kinship across human NGS data. PMC. 2025. (On curated common-SNP panels, sample-swap and sex-concordance checks.) ncbi.nlm.nih.gov/pmc/articles/PMC12838523
  2. Bergmann EA, Chen B-J, Arora K, Vacic V, Zody MC. Conpair: concordance and contamination estimator for matched tumor–normal pairs. Bioinformatics. 2016;32(20):3196–3198. ncbi.nlm.nih.gov/pmc/articles/PMC5048070
  3. Detecting sample swaps in diverse NGS data types using linkage disequilibrium. Nature Communications. 2020;11:3697. (Tool comparisons; concordance thresholds.) nature.com/articles/s41467-020-17453-5
  4. Quality and concordance of genotyping array data of 12,064 samples from 5840 cancer patients. PMC. 2019. (Blood–normal vs blood–tumor SNP concordance; LOH in tumors.) pmc.ncbi.nlm.nih.gov/articles/PMC6546549
© Zetobit LLC · Bioinformatics Insight Series zetobit.com
Previous
Previous

Microbiome Data Is Compositional: Why a Taxon Can Appear to Rise When Nothing About It Changed

Next
Next

RNA Velocity: Why a Confident Arrow of Cellular Direction Can Point the Wrong Way