Stat

Statistical foundations: convergence modes, limit theorems, concentration inequalities, and minimax lower-bound tools.

Sample 69 core · 53 supporting · 6 submodules This file provides the library's causal-agnostic model of an independent and identically distributed sample on a common ambient probability space. Limit 37 core · 55 supporting · 7 submodules Convergence concepts: convergence in probability and distribution, continuous mapping, and Slutsky-style composition rules. CLT 58 core · 52 supporting · 10 submodules Central limit theory: iid and triangular-array CLTs, Lindeberg conditions, and vector-valued versions used by the estimation layer. Minimax 10 to review 197 core · 329 supporting · 26 submodules Minimax lower-bound machinery: risk definitions, maximal couplings, coordinatewise overlap, Le Cam two-point methods, Pinsker/KL bridges, and rate statements for estimation problems. Empirical­Process 20 core · 13 supporting · 5 submodules Empirical-process theory: Rademacher complexities, maximal inequalities, moduli of continuity, and uniform laws for function classes. MEstimation 21 core · 16 supporting · 11 submodules M- and Z-estimation: consistency, asymptotic normality, and influence-function representations. Quantile 51 core · 66 supporting · 7 submodules Quantile processes: empirical quantiles, Bahadur representations, and joint sample-quantile asymptotics. UStatistic 2 to review 66 core · 87 supporting · 4 submodules Collects the U-statistic library: order-2 Hoeffding and variance tools, fixed-order m infrastructure, Hájek expansions, remainder negligibility, and the fixed-order CLT. Bootstrap 9 core · 2 supporting · 3 submodules Bootstrap foundations: resampling distributions and consistency of bootstrap approximations. Concentration 199 core · 303 supporting · 15 submodules Vendored concentration-of-measure library (a port of auto-res/lean-rademacher; see UPSTREAM.md). Coupling 26 core · 36 supporting · 1 submodule This module collects coupling-based statistical primitives. Finite­Rao­Blackwell 52 core · 77 supporting · 7 submodules Guarded finite conditional laws and Rao–Blackwell reductions for arbitrary finite-design pushforwards and uniform allocation experiments, with exact disintegration, finite-prior posteriors, factorization sufficiency, and real-valued minimax bridges. GMM 15 core · 9 supporting · 4 submodules Generalized method of moments: identification, consistency, and asymptotic normality of GMM estimators. Inference 22 core · 39 supporting · 9 submodules Inferential tooling: delta methods (scalar, functional, Hadamard), Wald/chi-squared statistics, and Slutsky ingredients. Nonparametric 144 core · 147 supporting · 7 submodules Top barrel for reusable nonparametric statistical methods: approximation theory, weighted least squares, local-polynomial and series/sieve estimators, and higher-order influence-function tools. Orthogonality 4 core · 5 supporting · 2 submodules Neyman orthogonality as a statistical property: definitions and the second-order remainder characterization. Polynomial­Tail 23 core · 33 supporting · 7 submodules Polynomial lower-tail moment analysis: the polynomial small-value tail law for a bounded positive variable, truncated inverse first/second moment asymptotics, the trimming-bias bound, and the bias-variance rate-balancing algebra. Privacy 9 core · 9 supporting · 1 submodule Differential privacy via the Laplace mechanism: the centered Laplace distribution and its density-ratio bound, scalar and finite-dimensional additive-noise release, pure and approximate ε-differential-privacy guarantees, post-processing closure, and Laplace-noise moment bounds. Sample­Split 23 core · 24 supporting · 7 submodules This module is the public import point for sample-splitting infrastructure used by cross-fitting and fold-based estimation arguments.
Gaussian­Covariance 7 core · 13 supporting This module defines the Gaussian covariance discrepancy on finite positive-definite matrices and derives its compact-model attainment, strict separation, perturbation stability, and finite-model-selection interfaces. ★ finiteCovarianceModel_populationGap

Gaussian covariance discrepancy and finite model selection

This module defines the Gaussian covariance discrepancy on finite positive-definite matrices and derives its compact-model attainment, strict separation, perturbation stability, and finite-model-selection interfaces. The model assumptions are stated separately from the matrix inequality, so the results can be reused for any finite family of covariance models.

abbrev PositiveCovariance reviewed
Causalean.Stat

For a finite coordinate type, the positive covariance matrices are real square matrices equipped with a proof of positive definiteness.

Definition (Lean source)
V :
Type*
PositiveCovariance V :
Type (max 0 u_2)
{K : Matrix V V ℝ // PosDef K}
Causalean.Stat.PositiveCovariance · Causalean/Stat/GaussianCovariance.lean:23
def gaussianCovarianceDiscrepancy reviewed
Causalean.Stat

For a candidate covariance matrix and target second-moment matrix, the Gaussian covariance discrepancy is log determinant plus inverse-weighted trace.

Definition (Lean source)
V :
Type u_1
shared
K T :
Matrix V V ℝ
gaussianCovarianceDiscrepancy K T :
log K.det + trace (K⁻¹ * T)
Causalean.Stat.gaussianCovarianceDiscrepancy · Causalean/Stat/GaussianCovariance.lean:28
def normalizedCovarianceDiscrepancy reviewed
Causalean.Stat

For positive-definite candidate and target covariances, the normalized Gaussian covariance discrepancy subtracts the criterion's value at the target.

Definition (Lean source)
V :
Type u_1
shared
normalizedCovarianceDiscrepancy K T :
Causalean.Stat.normalizedCovarianceDiscrepancy · Causalean/Stat/GaussianCovariance.lean:34 · uses PositiveCovariance
def IsDiscrepancyAttainedOn reviewed
Causalean.Stat

For a covariance model and target matrix, discrepancy attainment means that one model member has no larger Gaussian discrepancy than every other member.

Definition (Lean source)
V :
Type u_2
shared
T :
Matrix V V ℝ
IsDiscrepancyAttainedOn M T :
Prop
∃ K ∈ M,
∀ L ∈ M,
Causalean.Stat.IsDiscrepancyAttainedOn · Causalean/Stat/GaussianCovariance.lean:257 · uses PositiveCovariance
def HasCompactDiscrepancySublevel reviewed
Causalean.Stat

For a covariance model and target matrix, a compact discrepancy sublevel is a nonempty compact cut of the model below some criterion value.

Definition (Lean source)
V :
Type u_2
shared
T :
Matrix V V ℝ
HasCompactDiscrepancySublevel M T :
Prop
∃ c : ℝ,
clause 1
(M ∩ {K | gaussianCovarianceDiscrepancy (K : Matrix V V ℝ) T ≤ c}).Nonempty
clause 2
IsCompact (M ∩ {K | gaussianCovarianceDiscrepancy (K : Matrix V V ℝ) T ≤ c})
Causalean.Stat.HasCompactDiscrepancySublevel · Causalean/Stat/GaussianCovariance.lean:265 · uses PositiveCovariance
def covarianceModelLoss reviewed
Causalean.Stat

For a covariance model and target matrix, the population loss is the infimum Gaussian discrepancy over positive-definite model covariances.

Definition (Lean source)
V :
Type u_2
shared
T :
Matrix V V ℝ
covarianceModelLoss M T :
sInf ((fun K : PositiveCovariance V => gaussianCovarianceDiscrepancy (K : Matrix V V ℝ) T) '' M)
Causalean.Stat.covarianceModelLoss · Causalean/Stat/GaussianCovariance.lean:369 · uses PositiveCovariance
theorem finiteCovarianceModel_populationGap reviewed
Causalean.Stat

Given a finite family of covariance models whose members are compact and nonempty, and a positive-definite true covariance contained in at least one model, the population losses have the positive gap required by finite penalized model selection.

Formal statement
V :
Type u_2
shared
I :
Type u_3
shared
Nonempty I
models :
hcompact :
∀ i, IsCompact (models i)
hne :
∀ i, (models i).Nonempty
hcontains :
∃ i, T ∈ models i
∃ gap : ℝ,
0 < gap
conclusion 1
i ∈ Causalean.Stat.populationMinimizers (fun j => covarianceModelLoss (models j) T) :
j ∉ Causalean.Stat.populationMinimizers (fun k => covarianceModelLoss (models k) T) :
covarianceModelLoss (models i) T + gap ≤ covarianceModelLoss (models j) T
Proof (Lean source)
theorem finiteCovarianceModel_populationGap [Fintype V] [DecidableEq V] [Fintype I] [Nonempty I] (models : I → Set (PositiveCovariance V)) (hcompact : ∀ i, IsCompact (models i)) (hne : ∀ i, (models i).Nonempty) (T : PositiveCovariance V) (hcontains : ∃ i, T ∈ models i) : ∃ gap : ℝ, 0 < gap ∧ ∀ i ∈ populationMinimizers (fun j => covarianceModelLoss (models j) T), ∀ j ∉ populationMinimizers (fun k => covarianceModelLoss (models k) T), covarianceModelLoss (models i) T + gap ≤ covarianceModelLoss (models j) T := by classical let minimizers := populationMinimizers (fun j => covarianceModelLoss (models j) T) let bad : Finset I := Finset.univ.filter fun j => j ∉ minimizers by_cases hbad : bad.Nonempty · obtain ⟨j0, hj0bad, hj0min⟩ := Finset.exists_min_image bad (fun j => covarianceModelLoss (models j) T) hbad have hj0not : j0 ∉ minimizers := (Finset.mem_filter.mp hj0bad).2 have hj0T : T ∉ models j0 := by simpa [minimizers, populationMinimizers_covarianceModelLoss_iff models hcompact hne T hcontains j0] using hj0not have hbase_lt : gaussianCovarianceDiscrepancy (T : Matrix V V ℝ) T < covarianceModelLoss (models j0) T := lt_of_le_of_ne (covarianceModelLoss_ge_truth (hcompact j0) (hne j0) T) (fun h => hj0T ((covarianceModelLoss_eq_truth_iff (hcompact j0) (hne j0) T).mp h.symm)) refine ⟨covarianceModelLoss (models j0) T - gaussianCovarianceDiscrepancy (T : Matrix V V ℝ) T, sub_pos.mpr hbase_lt, ?_⟩ intro i hi j hj have hiT : T ∈ models i := by exact (populationMinimizers_covarianceModelLoss_iff models hcompact hne T hcontains i).mp hi have hjbad : j ∈ bad := Finset.mem_filter.mpr ⟨Finset.mem_univ _, hj⟩ rw [(covarianceModelLoss_eq_truth_iff (hcompact i) (hne i) T).2 hiT] linarith [hj0min j hjbad] · refine ⟨1, zero_lt_one, ?_⟩ intro i hi j hj exfalso exact hbad ⟨j, Finset.mem_filter.mpr ⟨Finset.mem_univ _, hj⟩⟩
13 supporting declarations (lemmas, instances)