Timepieces

Every great watch begins as a pile of parts on the bench.

Each Timepiece is a complete algorithm from population genetics, disassembled and rebuilt from scratch. Like a watchmaker laying out parts on the bench, we examine every gear before assembling the whole mechanism. Nothing is taken on faith. Nothing is hidden behind “see supplementary materials.”

Verification Status

Disclaimer

The code examples in each Timepiece are verified by automated unit tests that re-implement the documented functions and check their mathematical properties. No Timepiece has been independently verified by a domain expert. If you find an error – mathematical, pedagogical, or computational – please open an issue. The table below shows the current verification status.

The Timepieces are grouped by what they do, with verification status for each.

Simulators – tools that generate ground truth

#

Timepiece

Tests

Verified

What it does

IV

msprime

190

Neutral coalescent with recombination. The clockwork that generates ground truth.

XVI

SLiM

67

Forward-time simulation with natural selection. The forge that builds what the coalescent cannot.

XVIII

discoal

132

Coalescent simulation with selective sweeps via trajectory + structured coalescent.

Demographic inference – estimating population size history

#

Timepiece

Tests

Verified

What it does

I

PSMC

186

Population size history from a single diploid genome. The simplest inference Timepiece.

II

SMC++

112

Extends PSMC to multiple unphased genomes with a distinguished lineage approach.

XIII

Gamma-SMC

107

Ultrafast pairwise TMRCA inference with gamma-distributed posteriors.

XIV

PHLASH

130

GPU-accelerated Bayesian inference of population size history via SVGD.

SFS-based demographic inference – using the site frequency spectrum

#

Timepiece

Tests

Verified

What it does

X

moments

162

Demographic inference from the SFS using moment equations.

XI

dadi

84

Demographic inference from the SFS by solving the Wright-Fisher diffusion PDE.

XII

momi2

140

Demographic inference from the SFS via coalescent tensor algebra.

Genealogy and ARG inference – reconstructing ancestral histories

#

Timepiece

Tests

Verified

What it does

III

Li & Stephens HMM

158

The copying model: a haplotype as a mosaic of references. A gear inside many Timepieces.

V

ARGweaver

120

Bayesian ARG sampling with discretized time. SINGER’s predecessor.

VI

tsinfer

142

Deterministic tree sequence inference at biobank scale.

VII

SINGER

172

Bayesian ARG sampling with continuous time and two-HMM architecture.

VIII

Threads

56

Deterministic ARG inference at biobank scale with PBWT pre-filtering.

XVII

Relate

66

Genome-wide genealogy estimation via asymmetric painting + MCMC branch lengths.

Dating and selection – calibrating genealogies and detecting selection

#

Timepiece

Tests

Verified

What it does

IX

tsdate

139

Dates tree sequence nodes using the molecular clock.

XV

CLUES

93

Full-likelihood estimation of selection coefficients from gene trees and ancient DNA.