arXiv:2609.11449cs.LGSep 2026

Manuscript Offprint

arXiv:2609.11449

Prevalence Determines Precision:Silent Contamination in Detector-Defined Datasets

Jia Huang, Yankai Wan, Yangjun Ou

Abstract

A large share of machine learning datasets are not observed but constructed: a detector, heuristic, or model is run over a pool of candidates, and whatever it accepts becomes the dataset. Weak and distant supervision, pseudo-labelling, event extraction, and most anomaly-detection benchmarks all have this form. The precision of the resulting dataset is not a property of the detector. It is governed by the prevalence π\pi of true positives in the pool the detector is deployed on, through elementary Bayes. This is textbook, and it is nonetheless almost never measured end-to-end, for a structural reason: from inside a detector-defined dataset the false positives are unidentifiable, so the quantity that matters cannot be estimated by the people who need it. We report a case in which it can be measured. For the same instrument and period we hold both a detector-defined event dataset and an independent official index that reveals, for every detected item, whether it is real. One detector, three candidate pools, three datasets: phantom rates of 81.7%, 9.0%, and 0.0%. A practitioner transferring precision from the two high- π\pi pools to the low- π\pi pool predicts 0.955 against a measured 0.183, an error of +422%; the Bayes expression predicts within 3.3% across all three pools. Beyond confirming the mechanism we report three findings that we believe are new. First, the detected dataset’s response curve is an exact convex combination of a true-event and a phantom component (identity residual 1.1×10−161.1 \times 10^{-16}), with phantoms outnumbering true events 473 to 308 — contamination is not noise added to signal but a second signal with its own shape, inherited from the detector’s acceptance rule. Second, the direction of contamination is a property of the estimator, not of the data: on identical windows, one statistic shows contamination diluting the effect and another shows it inflating the effect, because the second statistic’s denominator is itself contaminated. Third, a normalisation in common use turns the estimator into a mean of ratios whose expectation does not exist; on the same 335 events it returns 0.40 where the well-defined estimator returns 0.10.

1 Introduction

Consider how a dataset gets built when nobody is willing to label 10610^6 items by hand. A rule is written — a regular expression, a knowledge-base join, a threshold on a model’s confidence, a statistical scan — and applied to a pool of candidates. What the rule accepts becomes the dataset. Downstream, the accepted items are treated as observations. This is the shape of distant supervision (Mintz et al., 2009), of weak supervision (Ratner et al., 2017), of pseudo-labelling, and of the great majority of event-detection and anomaly benchmarks.

The precision of such a dataset obeys

precision=πTPRπTPR+(1−π)FPR,(1)precision=\frac{\pi TPR}{\pi TPR+(1-\pi)FPR}, \tag{1}

where π\pi is the fraction of true positives in the pool the detector was run on. Precision is therefore a property of the deployment pool. What transfers across pools is the pair (TPR, FPR); precision does not. A detector validated where π≈1\pi \approx 1 — and at π≈1\pi \approx 1 even a badly broken detector looks flawless — and then redeployed where π≪1\pi \ll 1 imports false positives at a rate its validation never measured.

None of this is new. Bar-Hillel (1980) named the reasoning error; Hand (2009) and Saito & Rehmsmeier (2015) state the consequence for classifier evaluation directly. What is missing is measurement. The obstacle is structural rather than sociological: inside a detector-defined dataset the false positives are exactly the items one cannot identify. If they could be identified, the detector would not have accepted them. Practitioners therefore validate on whatever labelled subset they have — which is, almost by construction, a high- π\pi subset — and deploy elsewhere.

This paper. We report a setting where the phantoms are identifiable. For E-mini S&P 500 futures over 2010–2026 we hold two independent event indices over the same price series: a detector-defined set produced by a magnitude-threshold scan, and an official index (CPI, non-farm payrolls, and FOMC statement releases) published by the institutions that generate the events. Every detected item can be classified. Moreover the detector was run on three structurally different candidate pools — the Federal Reserve’s own meeting calendar, the set of first Fridays, and business days 6–16 of each month — giving three deployments of one detector at π∈{1.00,0.82,0.10}\pi \in \{1.00, 0.82, 0.10\} within a single dataset.

We use this to do three things a synthetic study cannot. We measure (1) against reality rather than assuming it. We decompose a real contaminated estimate into its true and phantom components exactly, and characterise what the phantom component looks like. And we show that the contamination’s effect on a downstream scientific conclusion is not even sign-stable across reasonable choices of estimator.