Mean sequencing depth from a read count, with Lander–Waterman Poisson coverage fractions, version 2.0.0
ngs-coverage-depth@2.0.0: this version's equations with their symbols, each constant's value, their sources and whether each was read, a worked example where the record holds one, its level and what it was checked against, the number of cases, and what was not checked. This version's record is not rewritten; a correction is added under Changes.
What this page can and cannot show
Level: Checked against a reference; Mean depth exact; Illumina's example reproduced; Poisson fractions a model, no measured prediction error. Reference kind: our own exact-arithmetic script and a hand-worked case; the source's own worked example, CPython standard library (fractions, decimal), 3.13.18.
Checked by this project, not independently reviewed. Every method on this page has its equations, constants, sources and cases on record, and its cases agree with the stated reference within the stated tolerance. A reader can follow each method's worked example by hand; that shows the stated method gives the stated answer for one set of inputs, and does not test the code. The other cases and their values are not printed, so a reader cannot re-run these checks. No independent scientist has yet reviewed them.
Every version of this method · Every method · What the levels mean
Version 2.0.0
Level: Checked against a reference; Mean depth exact; Illumina's example reproduced; Poisson fractions a model, no measured prediction error. Reference kind: our own exact-arithmetic script and a hand-worked case; the source's own worked example, CPython standard library (fractions, decimal), 3.13.18. ngs-coverage-depth@2.0.0
Built, not hosted. Generated from a snapshot of the library's records taken on 2026-11-25, as committed on 2026-11-25. A later snapshot replaces this one, so these records and this page can change.
Verification statement: mean depth C = LN/G by exact arithmetic and the Illumina 770-2011-022 worked example; the Poisson fractions are a model with no measured prediction error, their arithmetic compared with a second implementation in Python by a separate agent of the same model family (53 cases) and with mpmath's regularized upper gamma on the tail cases
C = L N_used / G, and under the Poisson model the uncovered fraction e^-C and the fraction of bases at depth k or more.
- How results are reported: none: full double precision; each model value below 1e-300 (the uncovered fraction, the uncovered length and each P(depth ≥ k)) is withheld on its own value, never reported as 0
- Uncertainty: Mean depth is exact arithmetic. The Poisson fractions are a model with no measured prediction error.
- Iterates: series, at most 1000000 iterations
- Reference, as its record states it: Illumina Technical Note 770-2011-022's worked example (depth 6.3, P(Y=3) and the uncovered fraction at the note's precision), and mpmath's regularized upper gamma on the tail cases
- Level confirmed by this project's ruling of 14 November 2026
What this page can and cannot show
What was checked
78 cases in 3 files, linked by this exact version.
Run through the tool at build against our own exact-arithmetic script and a hand-worked case; the source's own worked example, CPython standard library (fractions, decimal), 3.13.18: 39 agree within the tolerance the file states, 39 refuse as the case expects, 0 differ, 0 were not run.
File 1, 53 cases
- Where the expected values came from: our own exact-arithmetic script and a hand-worked case
- Recorded on: 2026-11-14
- Reference: second implementation (Python 3.13), 2026-11-14; licence BSD-3-Clause
- Tolerance as the file states it: mean depth and reads relative 1e-15 (near zero: absolute 1e-24 below 1e-9, in x for depth and 1 for reads and depth thresholds); Poisson fractions and lengths relative 1e-12 (exact below 1e-300, where values are withheld); log10 values absolute 1e-9; statuses, codes, units, counts and withheld rules exact
File 2, 23 cases
- Where the expected values came from: our own exact-arithmetic script and a hand-worked case
- Recorded on: 2026-11-14
- Reference: CPython standard library (fractions, decimal), 3.13.18; licence PSF-2.0
- Tolerance as the file states it: mean depth and reads relative 1e-15 (near zero: absolute 1e-24 below 1e-9, in x for depth and 1 for reads and depth thresholds); Poisson fractions and lengths relative 1e-12 (exact below 1e-300, where values are withheld); log10 values absolute 1e-9; statuses, codes, units, counts and withheld rules exact
File 3, 2 cases
- Where the expected values came from: the source's own worked example, Illumina Technical Note 770-2011-022 (Pub. No. 770-2011-022, current as of 1 December 2014), page 1 'Coverage Equation' (C = LN/G; C = (100 bp)(189e6)/(3e9 bp) = 6.3) and page 2 (Poisson P(Y=y) = C^y e^-C / y!; P(Y=3), P(Y<=3), the uncovered fraction), read in full 10 November 2026
- Recorded on: 2026-11-14
- Reference: CPython standard library (fractions, decimal), 3.13.18; licence PSF-2.0
- Tolerance as the file states it: mean depth and reads relative 1e-15 (near zero: absolute 1e-24 below 1e-9, in x for depth and 1 for reads and depth thresholds); Poisson fractions and lengths relative 1e-12 (exact below 1e-300, where values are withheld); log10 values absolute 1e-9; statuses, codes, units, counts and withheld rules exact
Apart from the worked example, the cases and their values are not printed here. This shows agreement with this project's recorded cases. It does not show that a method suits your work, and it is not a qualification.
What was not checked
Lander and Waterman 1988 itself (unread: the Poisson model is cited through Illumina's note); the fit of the Poisson model to any real library (overdispersion); targeted panels' on-target rates beyond the stated usable fraction.
Definition or model
A closed form: the result follows from the inputs by the equations alone.
A model of nature: it describes how a system behaves, and can be wrong about it.
Prediction error: none available.
Equations
Equation 1
C = L × N_used / G (C = LN/G, Illumina 770-2011-022 p. 1)
N_used = N × (2 if read pairs) × (1 − d) × u, d and u applied only when stated: the ×2 for read pairs is implied by the note's calculator text only, and (1 − d)u is the record's own construction
G is the haploid genome length, or the length of a defined target (p. 1)
kb, Mb and Gb are 10^3, 10^6 and 10^9 bp (decimal)
inputs are read as the exact value of their shortest decimal, and READ_LONGER_THAN_GENOME is decided on that value, while meanDepth, readsUsed and the Poisson fractions are in double precision
order of checks: the kit's checks of each argument (missing, number, unit, range), then READ_LONGER_THAN_GENOME, then the Poisson series
| Symbol | Meaning and unit |
|---|---|
| C | mean depth, x |
| L | length of one read, bp |
| N | read count in the stated basis |
| G | genome or target size, bp |
| d | duplicate fraction |
| u | usable fraction of the reads left after duplicates |
Source: Illumina Technical Note: Sequencing, "Estimating Sequencing Coverage", Pub. No. 770-2011-022, equation Coverage Equation C = LN/G and the Poisson P(Y = y) = C^y e^-C / y!, p. 1 to 2, current as of 12/01/14, as printed on the PDF; read in full on 2026-11-11 by an AI-assisted session; not yet checked by a person. Read from the file itself, SHA-256 beginning 90c533ee5a19. Free to read (© Illumina, Inc.; terms not stated on the page (held for the General Counsel)), checked 2026-11-11. No erratum found (searched the PDF's own date line (current as of 12/01/14)), 2026-11-11.
Equation 2
P(depth = y) = C^y e^-C / y!
uncovered fraction = e^-C, log10 uncovered fraction = -C / ln 10, uncovered length = G e^-C
P(depth ≥ k) = Σ_{y≥k} P(y), summed as Σ_{y≥k} t_y / Σ_y t_y with t_y = P(y)/P(mode), so neither tail cancels (this ratio-sum tail is the record's own construction)
the note also estimates the gap count as N·e^−C (p. 2, with no minimum overlap), withheld in this version: its printed 378,000 uses the uncovered fraction rounded to 0.2 %, where the model gives about 347,000
| Symbol | Meaning and unit |
|---|---|
| y | depth at a base |
| k | threshold depth |
Source: Illumina Technical Note: Sequencing, "Estimating Sequencing Coverage", Pub. No. 770-2011-022, equation Coverage Equation C = LN/G and the Poisson P(Y = y) = C^y e^-C / y!, p. 1 to 2, current as of 12/01/14, as printed on the PDF; read in full on 2026-11-11 by an AI-assisted session; not yet checked by a person. Read from the file itself, SHA-256 beginning 90c533ee5a19. Free to read (© Illumina, Inc.; terms not stated on the page (held for the General Counsel)), checked 2026-11-11. No erratum found (searched the PDF's own date line (current as of 12/01/14)), 2026-11-11.
Constants
Constants: none used.
Worked example
Worked example: one case of ngs-coverage-depth@2.0.0, from its inputs through each step to the answer. Values are written as a person writes them; the working carries more digits, so your own figure may differ in the last digit shown.
Inputs
- genomeSize = 3000000000 bp
- readLength = 100 bp
- readCount = 189000000
- readCountBasis = reads
- depthThresholds[0] = 1
- depthThresholds[1] = 4
- depthThresholds[2] = 10
Steps
- C = 6.3 x, from readLength, readCount, genomeSize; by equation 1; gives result.meanDepth.
- u = 0.0018363048, from C; by equation 2; gives result.model.uncoveredFraction.
The working, as the case writes it:
C = (100 bp)(189 x 10^6)/(3 x 10^9 bp) = 6.3, as printed. The note's P(Y=3) = 0.077 matches the unrounded 0.076527 at three places. Its P(Y<=3) = 0.077 + 0.036 + 0.012 + 0.002 = 0.127 is a sum of terms each rounded to three places
the unrounded value is 0.126374 (rounds to 0.126): it does not match and is not asserted (Drybench ruling, 10 November 2026, ruling 2). Uncovered 0.2 % matches the unrounded 0.1836 % at the note's precision. The note's 6,000,000 bp and 378,000 gaps use 0.2 % first
unrounded 5.509e6 bp and 347,062 (gaps are withheld from 1.0.0).
Answer
result.meanDepth= 6.3 xresult.model.uncoveredFraction= 0.0018363048
Where these values came from: the source's own worked example, Illumina Technical Note 770-2011-022 (Pub. No. 770-2011-022, current as of 1 December 2014), page 1 'Coverage Equation' (C = LN/G; C = (100 bp)(189e6)/(3e9 bp) = 6.3) and page 2 (Poisson P(Y=y) = C^y e^-C / y!; P(Y=3), P(Y<=3), the uncovered fraction), read in full 10 November 2026; Illumina Technical Note 770-2011-022 (current as of 1 December 2014), page 1 'Coverage Equation' and page 2 (Poisson), read in full 10 November 2026.
At build the tool returned this answer within the tolerance the file states: mean depth and reads relative 1e-15 (near zero: absolute 1e-24 below 1e-9, in x for depth and 1 for reads and depth thresholds); Poisson fractions and lengths relative 1e-12 (exact below 1e-300, where values are withheld); log10 values absolute 1e-9; statuses, codes, units, counts and withheld rules exact.
Who worked this case: not recorded.
What it refuses, and its input ranges
READ_LONGER_THAN_GENOME: the read length exceeds the genome or target size Next: Check that the genome size and the read length are in the units you meant.
Changes
2026-11-14-ngs-coverage-depth@2.0.0-1
2026-11-14 · ngs-coverage-depth@2.0.0 · Corrections to our methods
- What was wrong: Two withholding reasons in the reply said things that were not true. A P(depth ≥ k) withheld below 1e-300 sent the reader to log10UncoveredFraction, which is the log of P(depth = 0), not of the tail. expectedGaps was withheld because the gap formula was said to be in Lander and Waterman 1988, unread, but Illumina's note that was read gives the gap count as the reads used times the uncovered fraction (p. 2).
- Affected: The reply text of every computed reply in version 1.0.0 of the assistant tool ngs_coverage_depth (the expectedGaps reason), and of replies with a tail fraction below 1e-300. No number was affected.
- What changed: In 2.0.0 each value below 1e-300 is withheld with its own reason: the tail fraction's says it is not given in log form, and the uncovered length's names genomeSize. expectedGaps stays withheld, with a reason that names the note's estimate N·e^−C. The record lists the three withholdings, the decimal reading of inputs, the unit factors and the order of checks.
- How it was found: A second implementation in Python by a separate agent of the same model family, and the CSO's review, in the raising run's full check of 14 November 2026 (finding SEQ-F6).
- Cases added: stored reference values and stored reference values re-record the retired -1 and -2 at 2.0.0; stored reference values holds the second implementation's 53 cases at 2.0.0.
Tools that use it
Cite this version
Mean sequencing depth from a read count, with Lander–Waterman Poisson coverage fractions. Drybench; ngs-coverage-depth@2.0.0; https://www.drybench.com/methods/m/ngs-coverage-depth/2.0.0 (accessed [date]).