🔬 Genomic Epidemiology Outbreak Strain Typing Simulator
This simulation aids in the genomic analysis of outbreak strains. It provides users with tools to sequence and analyze genetic material, aiding in the identification and tracking of specific pathogen variants.
Collecting Isolates Across an Outbreak — Cases, Contacts, and Candidate Sources
Every outbreak investigation begins with specimens. Public health and clinical laboratories collect bacterial or viral isolates from confirmed cases, probable cases identified through contact tracing, and — wherever feasible — candidate environmental, food, or animal reservoir samples. Each isolate is cultured (or, for unculturable organisms, sequenced directly from clinical specimen) and banked for whole-genome sequencing, since the genome is the single most information-dense object available for reconstructing who infected whom.
- 10–50: Typical isolates per investigation (confirmed + probable cases)
- 24–72 h: Time to first isolate (from specimen receipt)
- 20–40%: Source-sampling success rate (environmental/food isolates recovered)
- ≥5: Minimum isolates for a usable tree (below this, topology is unstable)
What counts as an isolate, and why source sampling matters
A "case isolate" is the pathogen recovered from a patient’s clinical specimen — stool, blood, sputum, wound swab — confirmed by culture or molecular diagnostics. A "source isolate" is the pathogen recovered from a suspected vehicle: a food product, a water supply, an animal, or an environmental surface implicated by early epidemiological interviews.
Collecting source isolates is disproportionately valuable but disproportionately hard. Food items are often consumed or discarded before sampling; environmental reservoirs may have already been cleaned; and even when a sample is obtained, low pathogen load can make recovery unsuccessful. Investigators therefore prioritize sampling as early as possible and cast a wide net — leftover food in refrigerators, unopened retained product lots, processing-facility swabs — because a matching source isolate can convert a statistical association ("cases who ate X were more likely to fall ill") into direct genomic proof.
A source isolate that is genomically indistinguishable from the case isolates is one of the strongest pieces of evidence available in an outbreak investigation — it moves the conclusion from correlation to near-certainty.
Isolate banking, metadata, and chain of custody
Each isolate is logged with structured metadata that will later be essential for interpretation: patient or sample ID, collection date, specimen type, geographic location, and any known epidemiological links (shared meal, shared facility, household contact). Isolates are cryopreserved (typically at –80°C in glycerol stock) so that sequencing can be repeated or expanded as the investigation grows.
Consistent metadata capture is not a formality — it is what allows genomic clustering (Stage 3–4) to be cross-checked against epidemiological timing (Stage 5). A genomic cluster with no epidemiological linkage is a puzzle; an epidemiological cluster with no genomic linkage is a false lead. The two data streams are only powerful together.
Whole-Genome Sequencing — Resolution That Legacy Typing Methods Cannot Match
Older outbreak typing methods — pulsed-field gel electrophoresis (PFGE), multi-locus sequence typing (MLST), serotyping — examine a small, fixed slice of the genome: a handful of restriction fragments or a few dozen housekeeping genes. Whole-genome sequencing (WGS) reads essentially the entire genome, millions of base pairs, giving a discriminatory power that can distinguish genuinely related strains from coincidentally similar but epidemiologically unrelated ones — a distinction PFGE routinely cannot make.
- 2–6 Mb: Typical bacterial genome size (e.g. Salmonella ≈ 4.8 Mb)
- 30–100×: Sequencing depth used (coverage for reliable SNP calls)
- 24–48 h: Turnaround (rapid platforms) (sequencer run + assembly)
- ~4,000,000 vs ~7: Loci examined: WGS vs MLST (genome-wide vs housekeeping genes)
From PFGE fingerprints to genome-wide comparison
PFGE cuts genomic DNA with a restriction enzyme and separates the resulting fragments by size on a gel, producing a "fingerprint" of 10–20 bands. Two isolates with matching band patterns were historically called the "same strain." But band position depends only on the location of a handful of restriction sites — large genomic regions can differ substantially while restriction sites (and therefore the fingerprint) stay identical. PFGE also struggles with reproducibility across laboratories.
WGS instead reads every base of the genome using high-throughput short-read platforms (e.g. Illumina, generating millions of ~150 bp reads) or long-read platforms (e.g. Oxford Nanopore, generating reads of tens of kilobases). Reads are assembled or mapped against a reference genome, and every nucleotide position becomes a potential point of comparison between isolates — a resolution improvement of several orders of magnitude.
Two Listeria isolates that appear identical by PFGE can differ by only a handful of SNPs (truly linked) or by hundreds of SNPs (coincidentally similar, unrelated) — a distinction invisible to PFGE but obvious once the full genome is read.
Sequencing platforms and quality control
Short-read sequencing (Illumina MiSeq/NextSeq) remains the workhorse for outbreak genomics: high per-base accuracy (>99.9%), low cost per genome (roughly $20–100), and mature bioinformatics pipelines. Long-read platforms (Oxford Nanopore, PacBio) are increasingly used where rapid turnaround or complete genome assembly (e.g. resolving plasmids carrying resistance genes) matters more than the highest possible per-base accuracy.
Before any downstream comparison, sequencing data passes quality control: minimum coverage depth (commonly ≥30× across the genome), read quality trimming, contamination screening (is more than one organism present in the culture?), and species/serotype confirmation. A poorly sequenced genome can introduce false SNP differences that mimic evolutionary distance — QC failures are a leading cause of spurious "unrelated" calls in real investigations.
Phylogenetic Comparison — Building the Tree That Shows Shared Ancestry
Once genomes are sequenced, they must be compared. The dominant approach is reference-based SNP calling: every isolate’s reads are aligned to a common reference genome, and every position where an isolate differs from the reference (and from other isolates) is tallied as a single-nucleotide polymorphism. The resulting pairwise SNP distances are used to build a phylogenetic tree — a visual and quantitative map of which isolates share the most recent common ancestor, and therefore which cases are most likely linked by direct or short transmission chains.
- 1,500–3,000: Core-genome MLST allele targets (organism-dependent scheme)
- ≤5–10: SNP threshold — Salmonella (illustrative same-cluster cutoff)
- ≤10–15: SNP threshold — Listeria (illustrative same-cluster cutoff)
- IQ-TREE, RAxML: Tree-building tools (maximum-likelihood inference)
SNP calling and core-genome MLST — two roads to the same answer
Reference-based SNP calling: reads are mapped to a closely related reference genome; positions covered in all isolates and passing quality filters form a "core" alignment; every variant position across that core alignment is counted. Pairwise SNP distance is then simply the number of differing positions between two isolates’ core-genome sequences.
Core-genome MLST (cgMLST): rather than raw SNPs, cgMLST compares allele calls across a standardized, curated set of core genes (typically 1,500–3,000 loci for well-characterized pathogens). Each gene is assigned an allele number from a nomenclature database, and isolates are compared by counting differing alleles. cgMLST is more portable across laboratories (results are comparable without re-analyzing raw reads) and is now the standard for many public health networks, while SNP-based analysis remains the gold standard for the finest-scale resolution within a single well-defined outbreak.
Building and reading the tree
From the pairwise distance matrix (or the underlying multiple sequence alignment), a phylogenetic tree is inferred using maximum-likelihood methods (tools such as IQ-TREE or RAxML) or distance-based methods (neighbor-joining). The tree’s branch lengths represent genetic distance — short branches between isolates mean few differences and a recent shared ancestor; long branches mean many differences and a distant, likely unrelated, ancestor.
Isolates that cluster tightly together, connected by short branches, form a candidate transmission cluster. Isolates on long branches, far from the rest of the tree, are unlikely to share a recent transmission event with the outbreak cases — even if they cause the same disease and were sampled around the same time. This is the central insight WGS delivers that older typing cannot: apparent similarity (same species, same serotype, same rough time window) is not the same as genomic relatedness.
Bootstrap support values (how often a branching pattern reappears when the alignment is resampled) quantify confidence in the tree topology — a cluster supported by low bootstrap values should be treated cautiously, not as confirmed shared ancestry.
Outbreak Cluster Confirmation — Where to Draw the Line
A phylogenetic tree alone does not declare an outbreak cluster — someone has to decide how close is "close enough." Investigators apply an organism-specific SNP (or allele) distance threshold: isolates within that threshold of one another are considered part of the same transmission cluster, while isolates beyond it, despite superficial similarity in species or serotype, are treated as likely separate, unrelated introductions that merely happened to be sampled around the same time.
- <10–15 SNPs: Illustrative cluster threshold (varies by organism & mutation rate)
- ~1–2: Mutation rate — bacteria (typical) (SNPs per genome per year)
- Recombination: False-cluster risk factor (can inflate apparent SNP distance)
- Genomic + epi: Confirmation requires (neither alone is sufficient)
Why the threshold is organism-specific, not universal
The "right" SNP threshold depends on how fast an organism’s genome mutates and how much of the genome recombines. Slowly mutating, low-recombination organisms (e.g. Mycobacterium tuberculosis, roughly 0.5 SNPs per genome per year) can use a tight, highly specific threshold (often ≤12 SNPs defines a likely recent transmission link). Faster-evolving or recombination-prone organisms need looser or more carefully validated thresholds, because a single recombination event can introduce dozens of SNPs in one step — mimicking many independent mutations and inflating the apparent distance between isolates that are, in fact, closely linked.
Because of this, published thresholds are illustrative starting points, not universal laws: <5–10 SNPs for many Salmonella cluster investigations, <10–15 for Listeria monocytogenes, and organism- and even outbreak-specific calibration is standard practice, often validated against outbreaks with independently confirmed epidemiological links.
The two failure modes: false clustering and false splitting
Setting the threshold too loose risks false clustering: grouping together isolates that are coincidentally similar (e.g. a persistent, slowly-evolving strain circulating in a region for years) as if they represent one acute outbreak, triggering unnecessary and costly investigation of a phantom common source.
Setting the threshold too tight risks false splitting: separating isolates that are, in fact, part of the same transmission chain but happen to sit just outside the cutoff due to sequencing noise, within-host diversity, or a genuinely faster mutation event — causing investigators to miss a real, ongoing source of infection.
Neither genomic distance nor epidemiological plausibility is sufficient alone. A tight genomic cluster with no plausible shared exposure is a red flag for contamination, batch effects, or a shared long-term reservoir rather than a discrete outbreak. A plausible shared-exposure cluster with isolates far apart on the tree usually means the epidemiological hypothesis is wrong, or that more than one source is circulating simultaneously.
Genomic cluster confirmation should always be read together with epidemiological data — shared meals, facilities, travel, or contact history — before a threshold-based call is treated as final.
Transmission Chain Inference — From “Linked” to “Who Infected Whom”
Confirming that a set of cases belongs to one genomic cluster answers "are these connected?" It does not, by itself, answer "in what order, and through what pathway?" Combining the phylogenetic tree with epidemiological timing — symptom-onset dates, exposure windows, contact networks — lets investigators infer the most plausible direction and route of transmission between linked cases, informing where to focus control measures.
- Tree + timing + contacts: Inputs combined (genomic + epidemiological)
- Days – weeks: Typical incubation window used (organism-dependent)
- TransPhylo, outbreaker2: Specialized inference tools (joint phylogenetic-epi models)
- Likely source + pathway: Outcome (not absolute proof)
Why the tree alone cannot show direction
A phylogenetic tree shows relatedness and relative branching order, but it does not, by itself, encode "who infected whom" or the direction of spread — two isolates can sit on adjacent branches whether A infected B, B infected A, or both were infected independently by an unsampled common source. Directionality requires an additional axis of information that genomics alone does not provide: time.
Symptom onset dates, when combined with known incubation periods, let investigators order cases chronologically. An isolate genomically consistent with the cluster but with a symptom onset date earlier than all others is a stronger candidate for an early link (or the source itself) than one whose symptoms appeared last. Contact-tracing data — who ate together, who shared a ward, who had documented contact — further constrains which directional pathways are epidemiologically plausible at all.
Joint genomic-epidemiological transmission models
Purpose-built statistical tools formalize this combination rather than relying on manual inspection. Methods such as TransPhylo and outbreaker2 take a phylogenetic tree (or the sequence data directly) together with case timing data and a model of the pathogen’s within-host evolutionary rate and incubation period, and produce a probabilistic transmission tree: for each case, a ranked set of most-likely infectors, with associated confidence.
These models explicitly account for unsampled cases (an infection chain link that was never diagnosed, sequenced, or reported) and within-host diversity (a single host can carry a mixed population of closely related genotypes, complicating simple pairwise comparison). The output is not a certainty — it is a probability-weighted hypothesis about the transmission pathway, intended to focus further investigation and control measures (closing a facility, recalling a product, targeted contact follow-up) on the most plausible chain.
In the 2011 European Escherichia coli O104:H4 outbreak, whole-genome sequencing performed within days identified the near-clonal outbreak strain and its distinguishing virulence and resistance genes, enabling rapid, confident source attribution to contaminated fenugreek sprouts — a conclusion that legacy typing methods could not have reached with comparable speed or certainty.
This simulation aids in the genomic analysis of outbreak strains. It provides users with tools to sequence and analyze genetic material, aiding in the identification and tracking of specific pathogen variants.
2D · HTML5 Canvas 2D · 60 FPS target · runs fully client-side, no install