Interactive demo · Nonparametric Statistical Inference · Chapter 2

Confidence bands for a cdf: DKW against VC

The empirical cdf F̂n puts mass 1/n on each observation. The DKW inequality makes F̂n ± εn, with εn = √(log(2/α)/(2n)), a band that holds the whole cdf with probability at least 1 − α, for every F. The Vapnik–Chervonenkis inequality gives a band of the same kind for any class of sets of finite VC dimension, but for half-lines it is far wider: compare the two on the book's data. The lower panel checks the coverage claim by simulation (Exercise 2.3).

Data

Level α

Bands shown

Interval (a, b]

Simulation: F and n

Try these

Sample r (r = 0, 1, 2, ...) uses the seeded generator number 2300 + r and is drawn as Xi = F−1(Ui), so the same settings always give the same samples, and the Normal, Cauchy and Exponential choices see the same uniforms. The interval for F(b) − F(a) is the Normal-based interval (2.12) with the standard error of Exercise 2.8.

In the lecture notes