Experimentation.Unknown­Interference

Formalization of the Bernoulli-design core of Sävje, Aronow & Hudgens (2021), "Average treatment effects in the presence of unknown interference," *Annals of Statistics* 49(2):673–701 (arXiv:1711.06399).

Basic 11 core · 0 supporting The setup for "Average treatment effects in the presence of unknown interference" (Sävje, Aronow & Hudgens, *Annals of Statistics* 49(2), 2021). ★ Interferes★ InterfDep★ dbar★ EATE★ htEst★ y_update_eq_of_not_interferes★ y_eq_of_agree_on_interferers

Sävje–Aronow–Hudgens (2021): EATE estimand and the Horvitz–Thompson estimator

The setup for "Average treatment effects in the presence of unknown interference" (Sävje, Aronow & Hudgens, Annals of Statistics 49(2), 2021). A finite sample of units U is assigned a binary treatment vector z : U → Bool by a randomization design. Each unit's outcome y i z may depend on the entire assignment z — units interfere — but the form of the interference is unknown.

This file fixes the primitives:

* the interference indicator Interferes y ℓ i (changing 's treatment changes i's outcome under some assignment, plus the reflexive case ℓ = i), its symmetric closure InterfDep y i j (some interferes with both i and j), and the average interference dependence dbar (the paper's , the basis for the "restricted interference" assumption); * the assignment-conditional unit-level effect `tau y i z = y i (z with iᵗʰ coord 1) − y i (z with iᵗʰ coord 0), its average ACATE` (assignment-conditional ATE), and the expected average treatment effect EATE = E[ACATE(Z)] (Definition: the design average of the assignment-conditional ATE); * the Horvitz–Thompson estimator htEst.

The key structural fact proven here is y_eq_of_agree_on_interferers: a unit's outcome depends only on the treatments of the units that interfere with it — the bridge that turns "InterfDep fails" into "the two HT summands depend on disjoint coordinate blocks", which the disjoint-block independence lemma then turns into a vanishing covariance.

def Interferes reviewed
Causalean.Experimentation.UnknownInterference

Interference indicator. Unit interferes with unit i if changing 's treatment changes i's outcome under some assignment, or if ℓ = i (a unit always interferes with itself). y i z is unit i's outcome under the full assignment z.

Definition (Lean source)
def Interferes (y : U → (U → Bool) → ℝ) (ℓ i : U) : Prop := ℓ = i ∨ ∃ z : U → Bool, y i z ≠ y i (update z ℓ (! z ℓ))
Causalean.Experimentation.UnknownInterference.Interferes · Causalean/Experimentation/UnknownInterference/Basic.lean:50
def InterfDep reviewed
Causalean.Experimentation.UnknownInterference

Interference dependence. Units i and j are interference dependent if some unit interferes with both — i.e. they may be affected by a common treatment. The paper's d̄_{ij}.

Definition (Lean source)
def InterfDep (y : U → (U → Bool) → ℝ) (i j : U) : Prop := ∃ ℓ : U, Interferes y ℓ i ∧ Interferes y ℓ j
Causalean.Experimentation.UnknownInterference.InterfDep · Causalean/Experimentation/UnknownInterference/Basic.lean:56
def dbarCount reviewed
Causalean.Experimentation.UnknownInterference

The (unnormalized) count ∑ᵢ ∑ⱼ 1[InterfDep i j] of interference-dependent ordered pairs.

Definition (Lean source)
noncomputable def dbarCount (y : U → (U → Bool) → ℝ) : ℝ := ∑ i : U, ∑ j : U, if InterfDep y i j then (1 : ℝ) else 0
Causalean.Experimentation.UnknownInterference.dbarCount · Causalean/Experimentation/UnknownInterference/Basic.lean:62
def dbar reviewed
Causalean.Experimentation.UnknownInterference

Average interference dependence d̄ = n⁻¹ ∑ᵢ ∑ⱼ 1[InterfDep i j] — the paper's basic measure of the amount of interference. For a nonempty population, d̄ = 1 under no interference; d̄ = n when every pair is interference dependent. "Restricted interference" is the assumption d̄ = o(n).

Definition (Lean source)
noncomputable def dbar (y : U → (U → Bool) → ℝ) : ℝ := dbarCount y / (Fintype.card U : ℝ)
Causalean.Experimentation.UnknownInterference.dbar · Causalean/Experimentation/UnknownInterference/Basic.lean:66
def tau reviewed
Causalean.Experimentation.UnknownInterference

Assignment-conditional unit-level treatment effect. τ_i(z_{-i}) = y_i(1; z_{-i}) − y_i(0; z_{-i}), the effect of changing unit i's own treatment with all others held at z. Encoded on the full assignment via Function.update; it does not depend on z i.

Definition (Lean source)
def tau (y : U → (U → Bool) → ℝ) (i : U) (z : U → Bool) : ℝ := y i (update z i true) - y i (update z i false)
Causalean.Experimentation.UnknownInterference.tau · Causalean/Experimentation/UnknownInterference/Basic.lean:75
def ACATE reviewed
Causalean.Experimentation.UnknownInterference

Assignment-conditional average treatment effect ACATE(z) = n⁻¹ ∑ᵢ τ_i(z_{-i}).

Definition (Lean source)
noncomputable def ACATE (y : U → (U → Bool) → ℝ) (z : U → Bool) : ℝ := (∑ i : U, tau y i z) / (Fintype.card U : ℝ)
Causalean.Experimentation.UnknownInterference.ACATE · Causalean/Experimentation/UnknownInterference/Basic.lean:81
def EATE reviewed
Causalean.Experimentation.UnknownInterference

Expected average treatment effect (Definition, Sävje–Aronow–Hudgens 2021): EATE = E[ACATE(Z)], the design average of the assignment-conditional ATE. It generalizes the conventional ATE — under no interference ACATE(z) is constant in z, so the marginalization is inconsequential and EATE = ATE.

Definition (Lean source)
noncomputable def EATE (D : FiniteDesign (U → Bool)) (y : U → (U → Bool) → ℝ) : ℝ := D.E (ACATE y)
Causalean.Experimentation.UnknownInterference.EATE · Causalean/Experimentation/UnknownInterference/Basic.lean:85 · uses FiniteDesign
def htSummand reviewed
Causalean.Experimentation.UnknownInterference

The iᵗʰ Horvitz–Thompson summand Z_i Y_i / p_i − (1 − Z_i) Y_i / (1 − p_i), with Z_i = 1[z i] and Y_i = y i z.

Definition (Lean source)
noncomputable def htSummand (p : U → ℝ) (y : U → (U → Bool) → ℝ) (i : U) (z : U → Bool) : ℝ := (if z i then (1 : ℝ) else 0) * y i z / p i - (if z i then (0 : ℝ) else 1) * y i z / (1 - p i)
Causalean.Experimentation.UnknownInterference.htSummand · Causalean/Experimentation/UnknownInterference/Basic.lean:94
def htEst reviewed
Causalean.Experimentation.UnknownInterference

Horvitz–Thompson estimator htEst = n⁻¹ ∑ᵢ [Z_i Y_i / p_i − (1 − Z_i) Y_i / (1 − p_i)], with p i the marginal treatment probability of unit i.

Definition (Lean source)
noncomputable def htEst (p : U → ℝ) (y : U → (U → Bool) → ℝ) (z : U → Bool) : ℝ := (∑ i : U, htSummand p y i z) / (Fintype.card U : ℝ)
Causalean.Experimentation.UnknownInterference.htEst · Causalean/Experimentation/UnknownInterference/Basic.lean:100
lemma y_update_eq_of_not_interferes reviewed
Causalean.Experimentation.UnknownInterference

When unit does not interfere with unit i, flipping 's treatment while holding every other unit's assignment fixed never changes i's realized outcome.

Formal statement
y :
U → (U → Bool) → ℝ
ℓ i :
U
h :
¬ Interferes y ℓ i
z :
U → Bool
y i z = y i (update z ℓ (! z ℓ))
Proof (Lean source)
lemma y_update_eq_of_not_interferes {y : U → (U → Bool) → ℝ} {ℓ i : U} (h : ¬ Interferes y ℓ i) (z : U → Bool) : y i z = y i (update z ℓ (! z ℓ)) := by by_contra hne exact h (inr ⟨z, hne⟩)
Causalean.Experimentation.UnknownInterference.y_update_eq_of_not_interferes · Causalean/Experimentation/UnknownInterference/Basic.lean:111 · uses Interferes
theorem y_eq_of_agree_on_interferers reviewed
Causalean.Experimentation.UnknownInterference

A unit's outcome depends only on the units that interfere with it. If two treatment assignments z and z' agree on every unit that interferes with unit i, then unit i's outcome is the same under both assignments: y i z = y i z'.

Formal statement
y :
U → (U → Bool) → ℝ
i :
U
z z' :
U → Bool
h :
∀ ℓ : U
if
Interferes y ℓ i
then
z ℓ = z' ℓ
y i z = y i z'
Proof (Lean source)
theorem y_eq_of_agree_on_interferers (y : U → (U → Bool) → ℝ) (i : U) (z z' : U → Bool) (h : ∀ ℓ : U, Interferes y ℓ i → z ℓ = z' ℓ) : y i z = y i z' := by classical letI := ofFinite U -- Auxiliary: changing `z` to `z'` over a finset `S` of differing, non-interfering coordinates. -- We induct on the finset of coordinates where `z` and `z'` differ; `z` is generalized so the -- induction hypothesis applies to the updated assignment `w`. suffices H : ∀ S : Finset U, ∀ z : U → Bool, (∀ ℓ : U, z ℓ ≠ z' ℓ → ℓ ∈ S) → (∀ ℓ ∈ S, z ℓ ≠ z' ℓ → ¬ Interferes y ℓ i) → y i z = y i z' by refine H univ z (fun ℓ _ => Finset.mem_univ ℓ) (fun ℓ _ hne => ?_) intro hint exact hne (h ℓ hint) intro S induction S using Finset.induction with | empty => intro z hsub _ have hzz' : z = z' := by funext ℓ by_contra hne exact (notMem_empty ℓ) (hsub ℓ hne) rw [hzz'] | @insert a S ha ih => intro z hsub hnint -- Define `w`: equal to `z'` at `a`, equal to `z` elsewhere. set w : U → Bool := update z a (z' a) with hw -- Step 1: `y i z = y i w` (flipping the non-interferer coordinate `a`, if `z a ≠ z' a`). have step1 : y i z = y i w := by by_cases hza : z a = z' a · -- `a` not a differing coordinate; `w = z`. have : w = z := by rw [hw]; funext x by_cases hx : x = a · subst hx; rw [Function.update_self, hza] · rw [Function.update_of_ne hx] rw [this] · -- `a` differs, hence `¬ Interferes y a i`; `w = update z a (! z a)`. have haint : ¬ Interferes y a i := hnint a (mem_insert_self a S) hza have hflip : w = update z a (! z a) := by rw [hw]; congr 1 -- `z' a = ! z a` since they are distinct Bools. cases hzv : z a <;> cases hz'v : z' a <;> simp_all rw [hflip] exact y_update_eq_of_not_interferes haint z -- Step 2: `y i w = y i z'` by induction; `w` and `z'` differ only on `S`. have hsub' : ∀ ℓ : U, w ℓ ≠ z' ℓ → ℓ ∈ S := by intro ℓ hℓ have hℓa : ℓ ≠ a := by rintro rfl; rw [hw, Function.update_self] at hℓ; exact hℓ rfl have : w ℓ = z ℓ := by rw [hw, Function.update_of_ne hℓa] rw [this] at hℓ rcases Finset.mem_insert.mp (hsub ℓ hℓ) with h' | h' · exact absurd h' hℓa · exact h' have hnint' : ∀ ℓ ∈ S, w ℓ ≠ z' ℓ → ¬ Interferes y ℓ i := by intro ℓ hℓS hℓ have hℓa : ℓ ≠ a := fun hh => ha (hh ▸ hℓS) have hwz : w ℓ = z ℓ := by rw [hw, Function.update_of_ne hℓa] rw [hwz] at hℓ exact hnint ℓ (mem_insert_of_mem hℓS) hℓ rw [step1] exact ih w hsub' hnint'
Causalean.Experimentation.UnknownInterference.y_eq_of_agree_on_interferers · Causalean/Experimentation/UnknownInterference/Basic.lean:129 · uses Interferes
Bernoulli 4 core · 0 supporting Independent Bernoulli assignment supplies the product-design independence used for Sävje-Aronow-Hudgens unknown-interference results. ★ bernoulliDesign★ bernoulliDesign_E_eval★ bernoulliDesign_E_treat★ bernoulliDesign_E_ctrl

Bernoulli design under unknown interference

Independent Bernoulli assignment supplies the product-design independence used for Sävje-Aronow-Hudgens unknown-interference results.

This file reuses the canonical single-unit coinDesign, builds the product Bernoulli randomization design bernoulliDesign, and proves the one-coordinate marginal identities used throughout the Horvitz-Thompson and Hájek arguments. coinDesign_E expands the two-point expectation, bernoulliDesign_E_eval reduces any function of one unit's assignment to the corresponding coin expectation, and bernoulliDesign_E_treat / bernoulliDesign_E_ctrl give the marginal treatment and control probabilities p_i and 1 - p_i.

def bernoulliDesign reviewed
Causalean.Experimentation.UnknownInterference

The Bernoulli randomization design: each unit i is independently assigned treatment with probability p i. Built as the product of the per-unit coin designs.

Definition (Lean source)
noncomputable def bernoulliDesign (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) : FiniteDesign (U → Bool) := prodDesign (fun i => coinDesign (p i) (hp0 i) (hp1 i))
Causalean.Experimentation.UnknownInterference.bernoulliDesign · Causalean/Experimentation/UnknownInterference/Bernoulli.lean:44 · uses FiniteDesign
lemma bernoulliDesign_E_eval reviewed
Causalean.Experimentation.UnknownInterference

Marginalizing the Bernoulli design to a single coordinate. Under the Bernoulli design with per-unit treatment probabilities p taking values in [0, 1], the expected value of any function g of a single unit i's treatment status coincides with its expectation under that unit's own coin design with success probability p i — the Zᵢ ⊥ Z₋ᵢ marginalization.

Formal statement
p :
U → ℝ
hp0 :
∀ i, 0 ≤ p i
hp1 :
∀ i, p i ≤ 1
i :
U
g :
Bool → ℝ
(bernoulliDesign p hp0 hp1).E (fun z => g (z i)) = (coinDesign (p i) (hp0 i) (hp1 i)).E g
Proof (Lean source)
lemma bernoulliDesign_E_eval (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (i : U) (g : Bool → ℝ) : (bernoulliDesign p hp0 hp1).E (fun z => g (z i)) = (coinDesign (p i) (hp0 i) (hp1 i)).E g := FiniteDesign.E_prod_apply (fun i => coinDesign (p i) (hp0 i) (hp1 i)) i g
Causalean.Experimentation.UnknownInterference.bernoulliDesign_E_eval · Causalean/Experimentation/UnknownInterference/Bernoulli.lean:50 · uses E , coinDesign , bernoulliDesign
lemma bernoulliDesign_E_treat reviewed
Causalean.Experimentation.UnknownInterference

Marginal treatment-indicator expectation under the Bernoulli design. Under the Bernoulli design with per-unit treatment probabilities p taking values in [0, 1], the expected value of the indicator that unit i is treated equals p i.

Formal statement
p :
U → ℝ
hp0 :
∀ i, 0 ≤ p i
hp1 :
∀ i, p i ≤ 1
i :
U
(bernoulliDesign p hp0 hp1).E (fun z => if z i then (1 : ℝ) else 0) = p i
Proof (Lean source)
lemma bernoulliDesign_E_treat (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (i : U) : (bernoulliDesign p hp0 hp1).E (fun z => if z i then (1 : ℝ) else 0) = p i := by rw [bernoulliDesign_E_eval p hp0 hp1 i (fun b => if b then (1 : ℝ) else 0), coinDesign_E] simp
Causalean.Experimentation.UnknownInterference.bernoulliDesign_E_treat · Causalean/Experimentation/UnknownInterference/Bernoulli.lean:61 · uses E , bernoulliDesign
lemma bernoulliDesign_E_ctrl reviewed
Causalean.Experimentation.UnknownInterference

Marginal control-indicator expectation under the Bernoulli design. Under the Bernoulli design with per-unit treatment probabilities p taking values in [0, 1], the expected value of the indicator that unit i is untreated equals 1 - p i.

Formal statement
p :
U → ℝ
hp0 :
∀ i, 0 ≤ p i
hp1 :
∀ i, p i ≤ 1
i :
U
(bernoulliDesign p hp0 hp1).E (fun z => if z i then (0 : ℝ) else 1) = 1 - p i
Proof (Lean source)
lemma bernoulliDesign_E_ctrl (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (i : U) : (bernoulliDesign p hp0 hp1).E (fun z => if z i then (0 : ℝ) else 1) = 1 - p i := by rw [bernoulliDesign_E_eval p hp0 hp1 i (fun b => if b then (0 : ℝ) else 1), coinDesign_E] simp
Causalean.Experimentation.UnknownInterference.bernoulliDesign_E_ctrl · Causalean/Experimentation/UnknownInterference/Bernoulli.lean:69 · uses E , bernoulliDesign
Consistency 8 core · 2 supporting Horvitz-Thompson estimates the expected average treatment effect consistently when average interference is sparse. ★ SAHExperiment★ D_E_htEst★ D_Var_htEst_le★ chebyshev_eate★ htEst_consistent_eate★ root_n_var

Consistency under unknown interference

Horvitz-Thompson estimates the expected average treatment effect consistently when average interference is sparse.

This file packages one Sävje-Aronow-Hudgens Bernoulli experiment as SAHExperiment, including the finite unit type, treatment probabilities, potential outcomes, overlap bounds, moment bound, and regularity constant. The namespace-level bundle lemmas D_E_htEst, D_Var_htEst_le, and chebyshev_eate restate exact unbiasedness, the finite-sample variance bound, and the resulting Chebyshev tail inequality for the packaged experiment. The main sequence theorem htEst_consistent_eate proves convergence in probability when k^4 * dbar / n -> 0, and root_n_var records the root-n variance scaling under bounded average interference.

structure SAHExperiment reviewed
Causalean.Experimentation.UnknownInterference

A single Sävje–Aronow–Hudgens Bernoulli experiment, packaged so that a sequence of them models the growing-sample regime. Carries a finite population of units, marginal treatment probabilities, and potential outcomes indexed by the full assignment vector, together with an overlap regularity constant k at least one; the conditions that there is at least one unit, every treatment probability lies between 0 and 1, is bounded below by 1/k and above by 1 − 1/k (overlap); and every unit's potential outcome has second moment at most k² under the resulting Bernoulli design.

Definition (Lean source)
Finite population of units.
U :
Marginal treatment probabilities.
p :
U → ℝ
Potential outcomes `y i z` (unit `i`'s outcome under the full assignment `z`).
y :
U → (U → Bool) → ℝ
Regularity constant.
k :
`1 ≤ k`.
hk :
1 ≤ k
At least one unit.
hcard :
1 ≤ card U
Probabilities are in `[0,1]`.
hp0 :
∀ i, 0 ≤ p i
Probabilities are in `[0,1]`.
hp1 :
∀ i, p i ≤ 1
Lower overlap: `k⁻¹ ≤ p i`.
hplo :
∀ i, k⁻¹ ≤ p i
Upper overlap: `p i ≤ 1 − k⁻¹`.
hphi :
∀ i, p i ≤ 1 - k⁻¹
Second-moment bound: `E[Y_i²] ≤ k²`.
hmom :
∀ i, (bernoulliDesign p hp0 hp1).E (fun z => (y i z) ^ 2) ≤ k ^ 2
Causalean.Experimentation.UnknownInterference.SAHExperiment · Causalean/Experimentation/UnknownInterference/Consistency.lean:52
def D reviewed
Causalean.Experimentation.UnknownInterference.SAHExperiment

The Bernoulli design of the experiment.

Definition (Lean source)
noncomputable def D : FiniteDesign (E.U → Bool) := bernoulliDesign E.p E.hp0 E.hp1
Causalean.Experimentation.UnknownInterference.SAHExperiment.D · Causalean/Experimentation/UnknownInterference/Consistency.lean:92 · uses FiniteDesign , SAHExperiment
def eate reviewed
Causalean.Experimentation.UnknownInterference.SAHExperiment

The EATE estimand of the experiment.

Definition (Lean source)
noncomputable def eate : ℝ := EATE E.D E.y
Causalean.Experimentation.UnknownInterference.SAHExperiment.eate · Causalean/Experimentation/UnknownInterference/Consistency.lean:95 · uses SAHExperiment
theorem D_E_htEst reviewed
Causalean.Experimentation.UnknownInterference.SAHExperiment

Unbiasedness (bundle form). The Horvitz–Thompson estimator's expectation under the experiment's Bernoulli design equals the experiment's EATE estimand.

Formal statement
E.D.E (htEst E.p E.y) = E.eate
Proof (Lean source)
theorem D_E_htEst : E.D.E (htEst E.p E.y) = E.eate := by change E.D.E (htEst E.p E.y) = EATE E.D E.y unfold SAHExperiment.D rw [htEst_unbiased E.p E.hp0 E.hp1 E.p_ne_zero E.one_sub_p_ne_zero E.y]
Causalean.Experimentation.UnknownInterference.SAHExperiment.D_E_htEst · Causalean/Experimentation/UnknownInterference/Consistency.lean:113 · uses E , SAHExperiment , D , eate , htEst
theorem D_Var_htEst_le reviewed
Causalean.Experimentation.UnknownInterference.SAHExperiment

Variance bound (bundle form). The Horvitz–Thompson estimator's variance is at most the fourth power of the regularity constant times the average interference degree, divided by the population size.

Formal statement
E.D.Var (htEst E.p E.y) ≤ E.k ^ 4 * dbar E.y / (Fintype.card E.U : ℝ)
Proof (Lean source)
theorem D_Var_htEst_le : E.D.Var (htEst E.p E.y) ≤ E.k ^ 4 * dbar E.y / (Fintype.card E.U : ℝ) := by unfold SAHExperiment.D exact var_htEst_le E.p E.hp0 E.hp1 E.y E.k E.hk E.hcard E.hplo E.hphi E.hmom
Causalean.Experimentation.UnknownInterference.SAHExperiment.D_Var_htEst_le · Causalean/Experimentation/UnknownInterference/Consistency.lean:120 · uses Var , SAHExperiment , D , dbar , htEst
theorem chebyshev_eate reviewed
Causalean.Experimentation.UnknownInterference.SAHExperiment

Chebyshev tail bound. For any deviation threshold ε > 0, the probability that the Horvitz–Thompson estimator deviates from the EATE by at least ε is at most (k⁴·d̄/n)/ε², where k is the experiment's regularity constant, d̄ is the average interference degree, and n is the population size.

Formal statement
ε :
:
0 < ε
E.D.Pr (fun z => ε ≤ |htEst E.p E.y z - E.eate|)
≤ (E.k ^ 4 * dbar E.y / (Fintype.card E.U : ℝ)) / ε ^ 2
Proof (Lean source)
theorem chebyshev_eate {ε : ℝ} (hε : 0 < ε) : E.D.Pr (fun z => ε ≤ |htEst E.p E.y z - E.eate|) ≤ (E.k ^ 4 * dbar E.y / (Fintype.card E.U : ℝ)) / ε ^ 2 := by have hcheb := FiniteDesign.chebyshev E.D (htEst E.p E.y) hε rw [E.D_E_htEst] at hcheb have hε2 : (0 : ℝ) < ε ^ 2 := pow_pos hε 2 refine le_trans hcheb ?_ exact div_le_div_of_nonneg_right E.D_Var_htEst_le hε2.le
Causalean.Experimentation.UnknownInterference.SAHExperiment.chebyshev_eate · Causalean/Experimentation/UnknownInterference/Consistency.lean:128 · uses Pr , SAHExperiment , D , eate , dbar , htEst
theorem htEst_consistent_eate reviewed
Causalean.Experimentation.UnknownInterference

Consistency of Horvitz–Thompson for EATE under unknown interference (Sävje–Aronow–Hudgens 2021). Along a sequence of Bernoulli experiments along which k⁴·d̄/n → 0 — restricted interference with a controlled regularity constant, for every fixed deviation threshold ε > 0, the probability that the Horvitz–Thompson estimator deviates from the EATE by at least ε tends to zero along the sequence, i.e. the HT estimator converges in probability to the EATE.

Formal statement
Exp :
hrate :
Tendsto (fun m => (Exp m).k ^ 4 * dbar (Exp m).y / (card (Exp m).U : ℝ)) atTop (𝓝 0)
ε :
:
0 < ε
Tendsto (fun m => (Exp m).D.Pr (fun z => ε ≤ |htEst (Exp m).p (Exp m).y z - (Exp m).eate|)) atTop (𝓝 0)
Proof (Lean source)
theorem htEst_consistent_eate (Exp : ℕ → SAHExperiment) (hrate : Tendsto (fun m => (Exp m).k ^ 4 * dbar (Exp m).y / (card (Exp m).U : ℝ)) atTop (𝓝 0)) {ε : ℝ} (hε : 0 < ε) : Tendsto (fun m => (Exp m).D.Pr (fun z => ε ≤ |htEst (Exp m).p (Exp m).y z - (Exp m).eate|)) atTop (𝓝 0) := by have hupper : Tendsto (fun m => (Exp m).k ^ 4 * dbar (Exp m).y / (card (Exp m).U : ℝ) / ε ^ 2) atTop (𝓝 0) := by have := hrate.div_const (ε ^ 2) simpa using this refine squeeze_zero (fun m => ?_) (fun m => ?_) hupper · exact (Exp m).D.Pr_nonneg _ · exact (Exp m).chebyshev_eate
Causalean.Experimentation.UnknownInterference.htEst_consistent_eate · Causalean/Experimentation/UnknownInterference/Consistency.lean:143 · uses Pr , SAHExperiment , D , eate , dbar , htEst
theorem root_n_var reviewed
Causalean.Experimentation.UnknownInterference

Root-n variance scaling under bounded interference (Sävje–Aronow–Hudgens 2021). In one bundled experiment, if the average interference degree d̄ is bounded above by a constant C, then the sample size n times the variance of the Horvitz–Thompson estimator is at most k⁴·C, where k is the experiment's regularity constant — the finite-sample variance inequality that supports a root-n rate in bounded-interference sequences.

Formal statement
C :
hC :
dbar E.y ≤ C
(Fintype.card E.U : ℝ) * E.D.Var (htEst E.p E.y) ≤ E.k ^ 4 * C
Proof (Lean source)
theorem root_n_var (E : SAHExperiment) (C : ℝ) (hC : dbar E.y ≤ C) : (Fintype.card E.U : ℝ) * E.D.Var (htEst E.p E.y) ≤ E.k ^ 4 * C := by have hn : (0 : ℝ) < (Fintype.card E.U : ℝ) := by have : (1 : ℝ) ≤ (Fintype.card E.U : ℝ) := by exact_mod_cast E.hcard linarith have hk4 : (0 : ℝ) ≤ E.k ^ 4 := by positivity have hvar := E.D_Var_htEst_le have hstep : (Fintype.card E.U : ℝ) * E.D.Var (htEst E.p E.y) ≤ (Fintype.card E.U : ℝ) * (E.k ^ 4 * dbar E.y / (Fintype.card E.U : ℝ)) := mul_le_mul_of_nonneg_left hvar (le_of_lt hn) refine le_trans hstep ?_ rw [mul_div_assoc'] rw [mul_comm (Fintype.card E.U : ℝ) (E.k ^ 4 * dbar E.y), mul_div_assoc, div_self (ne_of_gt hn), mul_one] exact mul_le_mul_of_nonneg_left hC hk4
Causalean.Experimentation.UnknownInterference.root_n_var · Causalean/Experimentation/UnknownInterference/Consistency.lean:163 · uses Var , SAHExperiment , D , dbar , htEst
2 supporting declarations (lemmas, instances)
  • p_ne_zero lemma — The treatment probabilities are nonzero (from lower overlap).
    i :
    E.U
    E.p i ≠ 0
    Proof (Lean source)
    lemma p_ne_zero (i : E.U) : E.p i ≠ 0 := by have hkpos : (0 : ℝ) < E.k := lt_of_lt_of_le zero_lt_one E.hk have : (0 : ℝ) < E.p i := lt_of_lt_of_le (by positivity) (E.hplo i) exact ne_of_gt this
    Causalean.Experimentation.UnknownInterference.SAHExperiment.p_ne_zero · Causalean/Experimentation/UnknownInterference/Consistency.lean:98
  • one_sub_p_ne_zero lemma — One minus the treatment probability is nonzero (from upper overlap).
    i :
    E.U
    (1 : ℝ) - E.p i ≠ 0
    Proof (Lean source)
    lemma one_sub_p_ne_zero (i : E.U) : (1 : ℝ) - E.p i ≠ 0 := by have hkpos : (0 : ℝ) < E.k := lt_of_lt_of_le zero_lt_one E.hk have hkinv : (0 : ℝ) < E.k⁻¹ := by positivity have : (0 : ℝ) < 1 - E.p i := by have := E.hphi i linarith exact ne_of_gt this
    Causalean.Experimentation.UnknownInterference.SAHExperiment.one_sub_p_ne_zero · Causalean/Experimentation/UnknownInterference/Consistency.lean:104
Confidence 6 core · 0 supporting Chebyshev confidence statements remain valid under unknown interference when they use proven conservative variance bounds. ★ VhatBer★ E_VhatBer_bias★ var_htEst_le_inflated★ chebyshev_ci_eate★ eate_ci_kbound

Confidence under unknown interference

Chebyshev confidence statements remain valid under unknown interference when they use proven conservative variance bounds.

This file formalizes three finite-sample confidence facts for the Sävje-Aronow-Hudgens Bernoulli setup. The conventional variance estimator VhatBer has an exact expectation-bias identity E_VhatBer_bias, showing how off-diagonal covariances from interference can make it anti-conservative. The degree statistic degDep supports var_htEst_le_inflated, an in-expectation conservative inflation of VhatBer when each unit has bounded interference degree. Finally, chebyshev_ci_eate proves coverage for any positive conservative variance bound, and eate_ci_kbound instantiates it with the finite-sample variance bound k^4 * dbar / n.

def VhatBer reviewed
Causalean.Experimentation.UnknownInterference

The conventional Horvitz–Thompson variance estimator V̂_Ber = n⁻² ∑ᵢ ĤTᵢ². Pointwise this equals the paper's n⁻²[∑ᵢ ZᵢYᵢ²/pᵢ² + ∑ᵢ(1−Zᵢ)Yᵢ²/(1−pᵢ)²] (the cross term vanishes since Zᵢ(1−Zᵢ)=0).

Definition (Lean source)
noncomputable def VhatBer (p : U → ℝ) (y : U → (U → Bool) → ℝ) (z : U → Bool) : ℝ := (∑ i, (htSummand p y i z) ^ 2) / (Fintype.card U : ℝ) ^ 2
Causalean.Experimentation.UnknownInterference.VhatBer · Causalean/Experimentation/UnknownInterference/Confidence.lean:63
def degDep reviewed
Causalean.Experimentation.UnknownInterference

The interference degree of unit i: the number of units interference-dependent with i (d̄ᵢ = ∑ⱼ 1[InterfDep i j]).

Definition (Lean source)
noncomputable def degDep (y : U → (U → Bool) → ℝ) (i : U) : ℝ := ∑ j, if InterfDep y i j then (1 : ℝ) else 0
Causalean.Experimentation.UnknownInterference.degDep · Causalean/Experimentation/UnknownInterference/Confidence.lean:70
theorem E_VhatBer_bias reviewed
Causalean.Experimentation.UnknownInterference

The anti-conservativeness mechanism (Sävje–Aronow–Hudgens 2021). Under the Bernoulli design with per-unit treatment probabilities p taking values in [0, 1], the conventional variance estimator's expected value equals Var(ĤT) + n⁻²·(∑ᵢ(E ĤTᵢ)² − ∑ᵢ∑_{j≠i} Cov(ĤTᵢ,ĤTⱼ)): the true sampling variance of the Horvitz–Thompson estimator, plus the average squared per-unit mean, minus the off-diagonal covariances between units' Horvitz–Thompson summands.

Formal statement
p :
U → ℝ
hp0 :
∀ i, 0 ≤ p i
hp1 :
∀ i, p i ≤ 1
y :
U → (U → Bool) → ℝ
(bernoulliDesign p hp0 hp1).E (VhatBer p y)
= (bernoulliDesign p hp0 hp1).Var (htEst p y)
+ (∑ i, ((bernoulliDesign p hp0 hp1).E (htSummand p y i)) ^ 2 - ∑ i, ∑ j ∈ Finset.univ.erase i, (bernoulliDesign p hp0 hp1).Cov (htSummand p y i) (htSummand p y j)) / (Fintype.card U : ℝ) ^ 2
Proof (Lean source)
theorem E_VhatBer_bias (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (y : U → (U → Bool) → ℝ) : (bernoulliDesign p hp0 hp1).E (VhatBer p y) = (bernoulliDesign p hp0 hp1).Var (htEst p y) + (∑ i, ((bernoulliDesign p hp0 hp1).E (htSummand p y i)) ^ 2 - ∑ i, ∑ j ∈ Finset.univ.erase i, (bernoulliDesign p hp0 hp1).Cov (htSummand p y i) (htSummand p y j)) / (Fintype.card U : ℝ) ^ 2 := by set D := bernoulliDesign p hp0 hp1 with hD set n : ℝ := (Fintype.card U : ℝ) with hn rw [E_VhatBer_eq p hp0 hp1 y, Var_htEst_eq p hp0 hp1 y] -- `E[ĤTᵢ²] = Var(ĤTᵢ) + (E ĤTᵢ)²`. have hsq : ∀ i, D.E (fun z => (htSummand p y i z) ^ 2) = D.Var (htSummand p y i) + (D.E (htSummand p y i)) ^ 2 := by intro i; rw [D.Var_eq]; ring -- Split the inner full sum into the diagonal `Var` + the off-diagonal covariances. have hsplit : ∀ i, ∑ j, D.Cov (htSummand p y i) (htSummand p y j) = D.Var (htSummand p y i) + ∑ j ∈ Finset.univ.erase i, D.Cov (htSummand p y i) (htSummand p y j) := by intro i rw [← Finset.add_sum_erase univ (fun j => D.Cov (htSummand p y i) (htSummand p y j)) (Finset.mem_univ i)] rw [D.Cov_self] -- Rewrite both numerators. rw [Finset.sum_congr rfl (fun i _ => hsq i)] rw [Finset.sum_congr rfl (fun i _ => hsplit i)] -- Now both sides are sums divided by `n²`; collect over `n²`. rw [Finset.sum_add_distrib, Finset.sum_add_distrib] rcases eq_or_ne (n ^ 2) 0 with h0 | h0 · have : (Fintype.card U : ℝ) ^ 2 = 0 := by rw [← hn]; exact h0 rw [this]; simp · field_simp ring
theorem var_htEst_le_inflated reviewed
Causalean.Experimentation.UnknownInterference

Conservative inflation (Sävje–Aronow–Hudgens 2021). Under the Bernoulli design with per-unit treatment probabilities p taking values in [0, 1], if every unit's interference degree — the number of units it is interference-dependent with — is at most a bound D, then inflating the conventional variance estimator's expectation by a factor 1 + D gives a conservative bound on the Horvitz–Thompson estimator's true variance: Var(ĤT) ≤ (1 + D)·E[V̂_Ber].

Formal statement
p :
U → ℝ
hp0 :
∀ i, 0 ≤ p i
hp1 :
∀ i, p i ≤ 1
y :
U → (U → Bool) → ℝ
D :
hD :
∀ i, degDep y i ≤ D
(bernoulliDesign p hp0 hp1).Var (htEst p y)
≤ (1 + D) * (bernoulliDesign p hp0 hp1).E (VhatBer p y)
Proof (Lean source)
theorem var_htEst_le_inflated (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (y : U → (U → Bool) → ℝ) (D : ℝ) (hD : ∀ i, degDep y i ≤ D) : (bernoulliDesign p hp0 hp1).Var (htEst p y) ≤ (1 + D) * (bernoulliDesign p hp0 hp1).E (VhatBer p y) := by classical set Des := bernoulliDesign p hp0 hp1 with hDes set n : ℝ := (Fintype.card U : ℝ) with hn -- Abbreviation for `E[ĤTᵢ²]`, and its key facts. set Ec : U → ℝ := fun i => Des.E (fun z => (htSummand p y i z) ^ 2) with hEc have hEc_nonneg : ∀ i, 0 ≤ Ec i := fun i => Des.E_nonneg (fun _ => sq_nonneg _) have hVar_le : ∀ i, Des.Var (htSummand p y i) ≤ Ec i := by intro i; rw [Des.Var_eq]; have := sq_nonneg (Des.E (htSummand p y i)); linarith -- Symmetry of interference dependence. have hsymm : ∀ i j, InterfDep y i j → InterfDep y j i := by rintro i j ⟨ℓ, h1, h2⟩; exact ⟨ℓ, h2, h1⟩ -- Diagonal extraction: `∑ⱼ Cov(i,j) = Var(i) + ∑_{j≠i} Cov(i,j)`. have hsplit : ∀ i, ∑ j, Des.Cov (htSummand p y i) (htSummand p y j) = Des.Var (htSummand p y i) + ∑ j ∈ Finset.univ.erase i, Des.Cov (htSummand p y i) (htSummand p y j) := by intro i rw [← Finset.add_sum_erase univ (fun j => Des.Cov (htSummand p y i) (htSummand p y j)) (Finset.mem_univ i), Des.Cov_self] -- Off-diagonal covariance bound: `Cov(i,j) ≤ (Eᵢ+Eⱼ)/2` when dependent, `= 0` otherwise. have hcov_le : ∀ i j, Des.Cov (htSummand p y i) (htSummand p y j) ≤ (if InterfDep y i j then (Ec i + Ec j) / 2 else 0) := by intro i j by_cases hdep : InterfDep y i j · rw [if_pos hdep] have hVsub : 0 ≤ Des.Var (fun z => htSummand p y i z - htSummand p y j z) := Des.E_nonneg (fun _ => sq_nonneg _) rw [Des.Var_sub] at hVsub have hi := hVar_le i; have hj := hVar_le j; linarith · rw [if_neg hdep] exact le_of_eq (cov_htSummand_zero p hp0 hp1 y hdep) -- Off-diagonal double sum ≤ the `(Eᵢ+Eⱼ)/2` bound. have hoff_le : (∑ i, ∑ j ∈ Finset.univ.erase i, Des.Cov (htSummand p y i) (htSummand p y j)) ≤ ∑ i, ∑ j ∈ Finset.univ.erase i, (if InterfDep y i j then (Ec i + Ec j) / 2 else 0) := Finset.sum_le_sum (fun i _ => Finset.sum_le_sum (fun j _ => hcov_le i j)) -- Extend `erase i` to `univ` (nonneg terms). have hext : (∑ i, ∑ j ∈ Finset.univ.erase i, (if InterfDep y i j then (Ec i + Ec j) / 2 else 0)) ≤ ∑ i, ∑ j, (if InterfDep y i j then (Ec i + Ec j) / 2 else 0) := by refine Finset.sum_le_sum (fun i _ => ?_) refine Finset.sum_le_sum_of_subset_of_nonneg (Finset.erase_subset i univ) ?_ intro j _ _; by_cases hdep : InterfDep y i j · rw [if_pos hdep]; have := hEc_nonneg i; have := hEc_nonneg j; linarith · rw [if_neg hdep] -- Split the full double sum into `(S1 + S2)/2`. have hsplit2 : (∑ i, ∑ j, (if InterfDep y i j then (Ec i + Ec j) / 2 else 0)) = ((∑ i, ∑ j, (if InterfDep y i j then Ec i else 0)) + ∑ i, ∑ j, (if InterfDep y i j then Ec j else 0)) / 2 := by rw [← Finset.sum_add_distrib, Finset.sum_div] refine Finset.sum_congr rfl (fun i _ => ?_) rw [← Finset.sum_add_distrib, Finset.sum_div] refine Finset.sum_congr rfl (fun j _ => ?_) by_cases hdep : InterfDep y i j <;> simp [hdep] -- `S1 = ∑ᵢ Eᵢ·degDep i ≤ D·∑ᵢ Eᵢ`. have hS1 : (∑ i, ∑ j, (if InterfDep y i j then Ec i else 0)) ≤ D * ∑ i, Ec i := by have hrw : (∑ i, ∑ j, (if InterfDep y i j then Ec i else 0)) = ∑ i, Ec i * degDep y i := by refine Finset.sum_congr rfl (fun i _ => ?_) rw [degDep, Finset.mul_sum] refine Finset.sum_congr rfl (fun j _ => ?_) by_cases hdep : InterfDep y i j <;> simp [hdep] rw [hrw, Finset.mul_sum] refine Finset.sum_le_sum (fun i _ => ?_) rw [mul_comm (Ec i)] exact mul_le_mul_of_nonneg_right (hD i) (hEc_nonneg i) -- `S2`: swap order, use symmetry, same bound. have hS2 : (∑ i, ∑ j, (if InterfDep y i j then Ec j else 0)) ≤ D * ∑ i, Ec i := by rw [Finset.sum_comm] have hrw : (∑ j, ∑ i, (if InterfDep y i j then Ec j else 0)) = ∑ j, Ec j * degDep y j := by refine Finset.sum_congr rfl (fun j _ => ?_) rw [degDep, Finset.mul_sum] refine Finset.sum_congr rfl (fun i _ => ?_) by_cases hdep : InterfDep y j i · rw [if_pos (hsymm j i hdep), if_pos hdep, mul_one] · rw [if_neg (fun hc => hdep (hsymm i j hc)), if_neg hdep, mul_zero] rw [hrw, Finset.mul_sum] refine Finset.sum_le_sum (fun j _ => ?_) rw [mul_comm (Ec j)] exact mul_le_mul_of_nonneg_right (hD j) (hEc_nonneg j) -- Off-diagonal ≤ D·∑ᵢ Eᵢ. have hoff_D : (∑ i, ∑ j ∈ Finset.univ.erase i, Des.Cov (htSummand p y i) (htSummand p y j)) ≤ D * ∑ i, Ec i := by calc (∑ i, ∑ j ∈ Finset.univ.erase i, Des.Cov (htSummand p y i) (htSummand p y j)) ≤ ∑ i, ∑ j, (if InterfDep y i j then (Ec i + Ec j) / 2 else 0) := le_trans hoff_le hext _ = ((∑ i, ∑ j, (if InterfDep y i j then Ec i else 0)) + ∑ i, ∑ j, (if InterfDep y i j then Ec j else 0)) / 2 := hsplit2 _ ≤ D * ∑ i, Ec i := by linarith [hS1, hS2] -- Whole double sum ≤ (1+D)·∑ᵢ Eᵢ. have hdouble : (∑ i, ∑ j, Des.Cov (htSummand p y i) (htSummand p y j)) ≤ (1 + D) * ∑ i, Ec i := by rw [Finset.sum_congr rfl (fun i _ => hsplit i), Finset.sum_add_distrib] have hdiag : (∑ i, Des.Var (htSummand p y i)) ≤ ∑ i, Ec i := Finset.sum_le_sum (fun i _ => hVar_le i) have hexp : (1 + D) * ∑ i, Ec i = (∑ i, Ec i) + D * ∑ i, Ec i := by ring rw [hexp]; linarith [hdiag, hoff_D] -- Divide by `n²`. rw [Var_htEst_eq p hp0 hp1 y, E_VhatBer_eq p hp0 hp1 y, ← hEc, ← hn, ← mul_div_assoc] gcongr
Causalean.Experimentation.UnknownInterference.var_htEst_le_inflated · Causalean/Experimentation/UnknownInterference/Confidence.lean:148 · uses E , Var , VhatBer , bernoulliDesign , degDep , htEst
theorem chebyshev_ci_eate reviewed
Causalean.Experimentation.UnknownInterference

Chebyshev confidence interval for EATE. For the Bernoulli design with per-unit treatment probabilities p that take values in [0, 1] and are never exactly zero or one, for any value V that is positive and bounds the Horvitz–Thompson estimator's true sampling variance from above, and for any positive significance level α, the interval ĤT ± √(V/α) covers the EATE estimand with probability at least 1 − α.

Formal statement
p :
U → ℝ
hp0 :
∀ i, 0 ≤ p i
hp1 :
∀ i, p i ≤ 1
hp0' :
∀ i, p i ≠ 0
hp1' :
∀ i, (1 : ℝ) - p i ≠ 0
y :
U → (U → Bool) → ℝ
V α :
hV0 :
0 < V
hV :
(bernoulliDesign p hp0 hp1).Var (htEst p y) ≤ V
:
0 < α
1 - α
≤ (bernoulliDesign p hp0 hp1).Pr (fun z => |htEst p y z - EATE (bernoulliDesign p hp0 hp1) y| ≤ sqrt (V / α))
Proof (Lean source)
theorem chebyshev_ci_eate (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (hp0' : ∀ i, p i ≠ 0) (hp1' : ∀ i, (1 : ℝ) - p i ≠ 0) (y : U → (U → Bool) → ℝ) {V α : ℝ} (hV0 : 0 < V) (hV : (bernoulliDesign p hp0 hp1).Var (htEst p y) ≤ V) (hα : 0 < α) : 1 - α ≤ (bernoulliDesign p hp0 hp1).Pr (fun z => |htEst p y z - EATE (bernoulliDesign p hp0 hp1) y| ≤ sqrt (V / α)) := by classical set D := bernoulliDesign p hp0 hp1 with hD set t : ℝ := sqrt (V / α) with ht have hVα : 0 < V / α := div_pos hV0 hα have ht0 : 0 < t := Real.sqrt_pos.mpr hVα have ht2 : t ^ 2 = V / α := by rw [ht, Real.sq_sqrt (le_of_lt hVα)] have hμ : D.E (htEst p y) = EATE D y := htEst_unbiased p hp0 hp1 hp0' hp1' y -- Chebyshev: Pr(t ≤ |htEst - EATE|) ≤ Var / t² have hcheb := D.chebyshev (htEst p y) ht0 rw [hμ] at hcheb set A : (U → Bool) → Prop := fun z => |htEst p y z - EATE D y| ≤ t with hA set B : (U → Bool) → Prop := fun z => t ≤ |htEst p y z - EATE D y| with hB -- Pr B ≤ α. have hVt : D.Var (htEst p y) / t ^ 2 ≤ α := by rw [ht2] have hstep : D.Var (htEst p y) / (V / α) ≤ V / (V / α) := div_le_div_of_nonneg_right hV (by positivity) have hVdiv : V / (V / α) = α := by field_simp rw [hVdiv] at hstep; exact hstep have hPrB : D.Pr B ≤ α := le_trans hcheb hVt -- A and B cover everything: ind A + ind B ≥ 1 pointwise. have hcover : ∀ z, (1 : ℝ) ≤ FiniteDesign.ind A z + FiniteDesign.ind B z := by intro z rcases le_total (|htEst p y z - EATE D y|) t with h | h · have hi : FiniteDesign.ind A z = 1 := by unfold FiniteDesign.ind A; simp [h] have hBn : 0 ≤ FiniteDesign.ind B z := FiniteDesign.ind_nonneg B z rw [hi]; linarith · have hi : FiniteDesign.ind B z = 1 := by unfold FiniteDesign.ind B; simp [h] have hAn : 0 ≤ FiniteDesign.ind A z := FiniteDesign.ind_nonneg A z rw [hi]; linarith -- 1 = E[1] ≤ E[ind A + ind B] = Pr A + Pr B. have h1le : (1 : ℝ) ≤ D.Pr A + D.Pr B := by have hEmono : D.E (fun _ => (1 : ℝ)) ≤ D.E (fun z => FiniteDesign.ind A z + FiniteDesign.ind B z) := by unfold FiniteDesign.E exact Finset.sum_le_sum (fun z _ => mul_le_mul_of_nonneg_left (hcover z) (D.p_nonneg z)) rw [D.E_const, D.E_add] at hEmono change (1 : ℝ) ≤ D.E (FiniteDesign.ind A) + D.E (FiniteDesign.ind B) exact hEmono linarith [hPrB, h1le]
Causalean.Experimentation.UnknownInterference.chebyshev_ci_eate · Causalean/Experimentation/UnknownInterference/Confidence.lean:262 · uses Pr , Var , EATE , bernoulliDesign , htEst
theorem eate_ci_kbound reviewed
Causalean.Experimentation.UnknownInterference

A concrete finite-sample confidence interval for EATE (Sävje–Aronow–Hudgens 2021). Suppose the Bernoulli design has treatment probabilities p that lie in [0, 1], are never exactly zero or one, and in fact stay within [1/k, 1 - 1/k] for some regularity constant k ≥ 1; suppose also that the population is nonempty, every unit's outcome has second moment at most , and the significance level α is positive. Then the Chebyshev interval ĤT ± √(k⁴·d̄/(n·α)), where is the average interference degree and n the population size, covers the EATE estimand with probability at least 1 − α — a valid (conservative) interval that needs only the regularity constant k and the interference measure .

Formal statement
p :
U → ℝ
hp0 :
∀ i, 0 ≤ p i
hp1 :
∀ i, p i ≤ 1
hp0' :
∀ i, p i ≠ 0
hp1' :
∀ i, (1 : ℝ) - p i ≠ 0
y :
U → (U → Bool) → ℝ
k :
hk :
1 ≤ k
hcard :
1 ≤ Fintype.card U
hplo :
∀ i, k⁻¹ ≤ p i
hphi :
∀ i, p i ≤ 1 - k⁻¹
hmom :
∀ i, (bernoulliDesign p hp0 hp1).E (fun z => (y i z) ^ 2) ≤ k ^ 2
α :
:
0 < α
1 - α
≤ (bernoulliDesign p hp0 hp1).Pr (fun z => |htEst p y z - EATE (bernoulliDesign p hp0 hp1) y| ≤ sqrt (k ^ 4 * dbar y / ((Fintype.card U : ℝ) * α)))
Proof (Lean source)
theorem eate_ci_kbound (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (hp0' : ∀ i, p i ≠ 0) (hp1' : ∀ i, (1 : ℝ) - p i ≠ 0) (y : U → (U → Bool) → ℝ) (k : ℝ) (hk : 1 ≤ k) (hcard : 1 ≤ Fintype.card U) (hplo : ∀ i, k⁻¹ ≤ p i) (hphi : ∀ i, p i ≤ 1 - k⁻¹) (hmom : ∀ i, (bernoulliDesign p hp0 hp1).E (fun z => (y i z) ^ 2) ≤ k ^ 2) {α : ℝ} (hα : 0 < α) : 1 - α ≤ (bernoulliDesign p hp0 hp1).Pr (fun z => |htEst p y z - EATE (bernoulliDesign p hp0 hp1) y| ≤ sqrt (k ^ 4 * dbar y / ((Fintype.card U : ℝ) * α))) := by classical set V : ℝ := k ^ 4 * dbar y / (Fintype.card U : ℝ) with hVdef have hn0 : (0 : ℝ) < (Fintype.card U : ℝ) := by exact_mod_cast lt_of_lt_of_le zero_lt_one hcard have hk0 : (0 : ℝ) < k := lt_of_lt_of_le zero_lt_one hk have hdbar1 : 1 ≤ dbar y := one_le_dbar y hcard have hdbar0 : 0 < dbar y := lt_of_lt_of_le zero_lt_one hdbar1 have hV0 : 0 < V := by rw [hVdef]; positivity have hV : (bernoulliDesign p hp0 hp1).Var (htEst p y) ≤ V := var_htEst_le p hp0 hp1 y k hk hcard hplo hphi hmom have hci := chebyshev_ci_eate p hp0 hp1 hp0' hp1' y hV0 hV hα -- The interval radius matches: √(V/α) = √(k⁴·d̄/(n·α)). have harg : V / α = k ^ 4 * dbar y / ((Fintype.card U : ℝ) * α) := by rw [hVdef, div_div] rw [harg] at hci exact hci
Causalean.Experimentation.UnknownInterference.eate_ci_kbound · Causalean/Experimentation/UnknownInterference/Confidence.lean:339 · uses E , Pr , EATE , bernoulliDesign , dbar , htEst
Hajek 10 core · 9 supporting The Hájek estimator normalizes treated and control inverse-probability-weighted outcome sums by their realized weight sums. ★ hajekEst★ hajek_consistent_eate

Hájek estimation under unknown interference

The Hájek estimator normalizes treated and control inverse-probability-weighted outcome sums by their realized weight sums. This file defines those numerator and denominator components, proves their mean and variance controls under Bernoulli assignment, and combines them with the finite-design Slutsky tools to prove consistency for the Sävje-Aronow-Hudgens EATE estimand.

def htTreatSummand reviewed
Causalean.Experimentation.UnknownInterference

Treated Horvitz–Thompson summand Zᵢ Yᵢ / pᵢ.

Definition (Lean source)
noncomputable def htTreatSummand (p : U → ℝ) (y : U → (U → Bool) → ℝ) (i : U) (z : U → Bool) : ℝ := (if z i then (1 : ℝ) else 0) * y i z / p i
Causalean.Experimentation.UnknownInterference.htTreatSummand · Causalean/Experimentation/UnknownInterference/Hajek.lean:56
def htCtrlSummand reviewed
Causalean.Experimentation.UnknownInterference

Control Horvitz–Thompson summand (1 − Zᵢ) Yᵢ / (1 − pᵢ).

Definition (Lean source)
noncomputable def htCtrlSummand (p : U → ℝ) (y : U → (U → Bool) → ℝ) (i : U) (z : U → Bool) : ℝ := (if z i then (0 : ℝ) else 1) * y i z / (1 - p i)
Causalean.Experimentation.UnknownInterference.htCtrlSummand · Causalean/Experimentation/UnknownInterference/Hajek.lean:60
def weightTreatSummand reviewed
Causalean.Experimentation.UnknownInterference

Treated weight summand Zᵢ / pᵢ.

Definition (Lean source)
noncomputable def weightTreatSummand (p : U → ℝ) (i : U) (z : U → Bool) : ℝ := (if z i then (1 : ℝ) else 0) / p i
Causalean.Experimentation.UnknownInterference.weightTreatSummand · Causalean/Experimentation/UnknownInterference/Hajek.lean:64
def weightCtrlSummand reviewed
Causalean.Experimentation.UnknownInterference

Control weight summand (1 − Zᵢ) / (1 − pᵢ).

Definition (Lean source)
noncomputable def weightCtrlSummand (p : U → ℝ) (i : U) (z : U → Bool) : ℝ := (if z i then (0 : ℝ) else 1) / (1 - p i)
Causalean.Experimentation.UnknownInterference.weightCtrlSummand · Causalean/Experimentation/UnknownInterference/Hajek.lean:68
def AhatTreat reviewed
Causalean.Experimentation.UnknownInterference

The treated numerator average Â₁ = n⁻¹ ∑ᵢ Zᵢ Yᵢ / pᵢ.

Definition (Lean source)
noncomputable def AhatTreat (p : U → ℝ) (y : U → (U → Bool) → ℝ) (z : U → Bool) : ℝ := (∑ i, htTreatSummand p y i z) / (Fintype.card U : ℝ)
Causalean.Experimentation.UnknownInterference.AhatTreat · Causalean/Experimentation/UnknownInterference/Hajek.lean:72
def AhatCtrl reviewed
Causalean.Experimentation.UnknownInterference

The control numerator average Â₀ = n⁻¹ ∑ᵢ (1−Zᵢ) Yᵢ / (1−pᵢ).

Definition (Lean source)
noncomputable def AhatCtrl (p : U → ℝ) (y : U → (U → Bool) → ℝ) (z : U → Bool) : ℝ := (∑ i, htCtrlSummand p y i z) / (Fintype.card U : ℝ)
Causalean.Experimentation.UnknownInterference.AhatCtrl · Causalean/Experimentation/UnknownInterference/Hajek.lean:76
def BhatTreat reviewed
Causalean.Experimentation.UnknownInterference

The treated weight average B̂₁ = n⁻¹ ∑ᵢ Zᵢ / pᵢ.

Definition (Lean source)
noncomputable def BhatTreat (p : U → ℝ) (z : U → Bool) : ℝ := (∑ i, weightTreatSummand p i z) / (Fintype.card U : ℝ)
Causalean.Experimentation.UnknownInterference.BhatTreat · Causalean/Experimentation/UnknownInterference/Hajek.lean:80
def BhatCtrl reviewed
Causalean.Experimentation.UnknownInterference

The control weight average B̂₀ = n⁻¹ ∑ᵢ (1−Zᵢ) / (1−pᵢ).

Definition (Lean source)
noncomputable def BhatCtrl (p : U → ℝ) (z : U → Bool) : ℝ := (∑ i, weightCtrlSummand p i z) / (Fintype.card U : ℝ)
Causalean.Experimentation.UnknownInterference.BhatCtrl · Causalean/Experimentation/UnknownInterference/Hajek.lean:84
def hajekEst reviewed
Causalean.Experimentation.UnknownInterference

The Hájek estimator ĤA = Â₁/B̂₁ − Â₀/B̂₀, the realized-weight-normalized inverse-probability-weighted estimator.

Definition (Lean source)
noncomputable def hajekEst (p : U → ℝ) (y : U → (U → Bool) → ℝ) (z : U → Bool) : ℝ := AhatTreat p y z / BhatTreat p z - AhatCtrl p y z / BhatCtrl p z
Causalean.Experimentation.UnknownInterference.hajekEst · Causalean/Experimentation/UnknownInterference/Hajek.lean:88
theorem hajek_consistent_eate reviewed
Causalean.Experimentation.UnknownInterference

Consistency of the Hájek estimator for EATE (Sävje–Aronow–Hudgens 2021). Along a sequence of Bernoulli experiments for which the regularity constants are uniformly bounded above by a constant M, k⁴·d̄/n → 0 along the sequence — restricted interference, and the mean absolute treated and control potential outcomes are each bounded by that experiment's own regularity constant k (the paper's Assumption C), the Hájek estimator converges in probability to the EATE.

Formal statement
Exp :
M :
hM :
∀ m, (Exp m).k ≤ M
hrate :
Tendsto (fun m => (Exp m).k ^ 4 * dbar (Exp m).y / (card (Exp m).U : ℝ)) atTop (𝓝 0)
hpo1 :
∀ m i, (Exp m).D.E (fun z => |(Exp m).y i (update z i true)|) ≤ (Exp m).k
hpo0 :
∀ m i, (Exp m).D.E (fun z => |(Exp m).y i (update z i false)|) ≤ (Exp m).k
FiniteDesign.TendstoInProb (fun m => (Exp m).D) (fun m => hajekEst (Exp m).p (Exp m).y) (fun m => (Exp m).eate)
Proof (Lean source)
theorem hajek_consistent_eate (Exp : ℕ → SAHExperiment) (M : ℝ) (hM : ∀ m, (Exp m).k ≤ M) (hrate : Tendsto (fun m => (Exp m).k ^ 4 * dbar (Exp m).y / (card (Exp m).U : ℝ)) atTop (𝓝 0)) (hpo1 : ∀ m i, (Exp m).D.E (fun z => |(Exp m).y i (update z i true)|) ≤ (Exp m).k) (hpo0 : ∀ m i, (Exp m).D.E (fun z => |(Exp m).y i (update z i false)|) ≤ (Exp m).k) : FiniteDesign.TendstoInProb (fun m => (Exp m).D) (fun m => hajekEst (Exp m).p (Exp m).y) (fun m => (Exp m).eate) := by set D : ∀ m, FiniteDesign ((Exp m).U → Bool) := fun m => (Exp m).D with hDdef -- The numerator means (limit sequences for `Â₁`, `Â₀`). set ybar1 : ℕ → ℝ := fun m => (D m).E (AhatTreat (Exp m).p (Exp m).y) with hybar1 set ybar0 : ℕ → ℝ := fun m => (D m).E (AhatCtrl (Exp m).p (Exp m).y) with hybar0 -- Unfold `D m` to the underlying Bernoulli design. have hDm : ∀ m, D m = bernoulliDesign (Exp m).p (Exp m).hp0 (Exp m).hp1 := by intro m; simp only [hDdef, SAHExperiment.D] -- (A) Variance → 0 facts. have hvarA1 : Tendsto (fun m => (D m).Var (AhatTreat (Exp m).p (Exp m).y)) atTop (𝓝 0) := by refine squeeze_zero (fun m => Var_nonneg (D m) _) (fun m => ?_) hrate rw [hDm m] exact var_AhatTreat_le (Exp m).p (Exp m).hp0 (Exp m).hp1 (Exp m).y (Exp m).k (Exp m).hk (Exp m).hcard (Exp m).hplo (Exp m).hmom have hvarA0 : Tendsto (fun m => (D m).Var (AhatCtrl (Exp m).p (Exp m).y)) atTop (𝓝 0) := by refine squeeze_zero (fun m => Var_nonneg (D m) _) (fun m => ?_) hrate rw [hDm m] exact var_AhatCtrl_le (Exp m).p (Exp m).hp0 (Exp m).hp1 (Exp m).y (Exp m).k (Exp m).hk (Exp m).hcard (Exp m).hphi (Exp m).hmom -- The `k²/n ≤ k⁴·d̄/n` squeeze for the weight variances. have hweightle : ∀ m, (Exp m).k ^ 2 / (card (Exp m).U : ℝ) ≤ (Exp m).k ^ 4 * dbar (Exp m).y / (card (Exp m).U : ℝ) := by intro m have hn0 : (0 : ℝ) < (card (Exp m).U : ℝ) := by exact_mod_cast lt_of_lt_of_le zero_lt_one (Exp m).hcard apply div_le_div_of_nonneg_right _ hn0.le have hk1 : (1 : ℝ) ≤ (Exp m).k := (Exp m).hk have hd1 : (1 : ℝ) ≤ dbar (Exp m).y := one_le_dbar (Exp m).y (Exp m).hcard have hk2 : (1 : ℝ) ≤ (Exp m).k ^ 2 := by nlinarith [hk1] have hk4 : (Exp m).k ^ 2 ≤ (Exp m).k ^ 4 := by nlinarith [hk1, hk2] have hstep : (Exp m).k ^ 4 ≤ (Exp m).k ^ 4 * dbar (Exp m).y := by nlinarith [hd1, pow_nonneg (le_trans zero_le_one hk1) 4] linarith have hvarB1 : Tendsto (fun m => (D m).Var (BhatTreat (Exp m).p)) atTop (𝓝 0) := by refine squeeze_zero (fun m => Var_nonneg (D m) _) (fun m => ?_) hrate refine le_trans ?_ (hweightle m) rw [hDm m] exact var_BhatTreat_le (Exp m).p (Exp m).hp0 (Exp m).hp1 (Exp m).k (Exp m).hk (Exp m).hcard (Exp m).hplo have hvarB0 : Tendsto (fun m => (D m).Var (BhatCtrl (Exp m).p)) atTop (𝓝 0) := by refine squeeze_zero (fun m => Var_nonneg (D m) _) (fun m => ?_) hrate refine le_trans ?_ (hweightle m) rw [hDm m] exact var_BhatCtrl_le (Exp m).p (Exp m).hp0 (Exp m).hp1 (Exp m).k (Exp m).hk (Exp m).hcard (Exp m).hphi -- (B) Component convergences. have hA1 : FiniteDesign.TendstoInProb D (fun m => AhatTreat (Exp m).p (Exp m).y) ybar1 := FiniteDesign.tendstoInProb_of_var D _ hvarA1 have hA0 : FiniteDesign.TendstoInProb D (fun m => AhatCtrl (Exp m).p (Exp m).y) ybar0 := FiniteDesign.tendstoInProb_of_var D _ hvarA0 have hB1 : FiniteDesign.TendstoInProb D (fun m => BhatTreat (Exp m).p) (fun _ => 1) := by have hraw := FiniteDesign.tendstoInProb_of_var D (fun m => BhatTreat (Exp m).p) hvarB1 have heq : (fun m => (D m).E (BhatTreat (Exp m).p)) = (fun _ => (1 : ℝ)) := by funext m; rw [hDm m] exact E_BhatTreat (Exp m).p (Exp m).hp0 (Exp m).hp1 (Exp m).p_ne_zero (Exp m).hcard rw [heq] at hraw; exact hraw have hB0 : FiniteDesign.TendstoInProb D (fun m => BhatCtrl (Exp m).p) (fun _ => 1) := by have hraw := FiniteDesign.tendstoInProb_of_var D (fun m => BhatCtrl (Exp m).p) hvarB0 have heq : (fun m => (D m).E (BhatCtrl (Exp m).p)) = (fun _ => (1 : ℝ)) := by funext m; rw [hDm m] exact E_BhatCtrl (Exp m).p (Exp m).hp0 (Exp m).hp1 (Exp m).one_sub_p_ne_zero (Exp m).hcard rw [heq] at hraw; exact hraw -- (C) Ratios via Slutsky. have hbound1 : ∀ m, |ybar1 m| ≤ M := by intro m refine le_trans ?_ (hM m) change |(D m).E (AhatTreat (Exp m).p (Exp m).y)| ≤ (Exp m).k rw [hDm m] exact abs_E_AhatTreat_le (Exp m).p (Exp m).hp0 (Exp m).hp1 (Exp m).p_ne_zero (Exp m).y (Exp m).k (Exp m).hk (Exp m).hcard (by intro i; have := hpo1 m i; unfold SAHExperiment.D at this; exact this) have hbound0 : ∀ m, |ybar0 m| ≤ M := by intro m refine le_trans ?_ (hM m) change |(D m).E (AhatCtrl (Exp m).p (Exp m).y)| ≤ (Exp m).k rw [hDm m] exact abs_E_AhatCtrl_le (Exp m).p (Exp m).hp0 (Exp m).hp1 (Exp m).one_sub_p_ne_zero (Exp m).y (Exp m).k (Exp m).hk (Exp m).hcard (by intro i; have := hpo0 m i; unfold SAHExperiment.D at this; exact this) have hR1 : FiniteDesign.TendstoInProb D (fun m z => AhatTreat (Exp m).p (Exp m).y z / BhatTreat (Exp m).p z) ybar1 := FiniteDesign.tendstoInProb_div_one D _ _ ybar1 M hbound1 hA1 hB1 have hR0 : FiniteDesign.TendstoInProb D (fun m z => AhatCtrl (Exp m).p (Exp m).y z / BhatCtrl (Exp m).p z) ybar0 := FiniteDesign.tendstoInProb_div_one D _ _ ybar0 M hbound0 hA0 hB0 -- (D) Difference. have hdiff := hR1.sub hR0 -- The statistic is exactly `hajekEst`. have hstat : (fun m z => AhatTreat (Exp m).p (Exp m).y z / BhatTreat (Exp m).p z - AhatCtrl (Exp m).p (Exp m).y z / BhatCtrl (Exp m).p z) = (fun m => hajekEst (Exp m).p (Exp m).y) := by funext m z; rw [hajekEst] -- The limit sequence is `eate`. have hlim : (fun m => ybar1 m - ybar0 m) = (fun m => (Exp m).eate) := by funext m change (D m).E (AhatTreat (Exp m).p (Exp m).y) - (D m).E (AhatCtrl (Exp m).p (Exp m).y) = (Exp m).eate rw [SAHExperiment.eate, EATE, hDm m] have hsub := E_AhatTreat_sub_E_AhatCtrl (Exp m).p (Exp m).hp0 (Exp m).hp1 (Exp m).p_ne_zero (Exp m).one_sub_p_ne_zero (Exp m).y rw [EATE] at hsub rw [show SAHExperiment.D (Exp m) = bernoulliDesign (Exp m).p (Exp m).hp0 (Exp m).hp1 from hDm m] exact hsub rw [hstat, hlim] at hdiff exact hdiff
Causalean.Experimentation.UnknownInterference.hajek_consistent_eate · Causalean/Experimentation/UnknownInterference/Hajek.lean:706 · uses E , TendstoInProb , SAHExperiment , D , eate , dbar , hajekEst
9 supporting declarations (lemmas, instances)
  • E_BhatTreat theorem — With nonzero treatment propensities and a nonempty population, the treated weight average has mean exactly one: E[B̂₁] = 1.
    p :
    U → ℝ
    hp0 :
    ∀ i, 0 ≤ p i
    hp1 :
    ∀ i, p i ≤ 1
    hp0' :
    ∀ i, p i ≠ 0
    hcard :
    1 ≤ card U
    (bernoulliDesign p hp0 hp1).E (BhatTreat p) = 1
    Proof (Lean source)
    theorem E_BhatTreat (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (hp0' : ∀ i, p i ≠ 0) (hcard : 1 ≤ Fintype.card U) : (bernoulliDesign p hp0 hp1).E (BhatTreat p) = 1 := by set D := bernoulliDesign p hp0 hp1 with hD set n : ℝ := (Fintype.card U : ℝ) with hn have hn0 : n ≠ 0 := by rw [hn]; exact_mod_cast Nat.one_le_iff_ne_zero.mp hcard have h1 : D.E (BhatTreat p) = (1 / n) * ∑ i : U, D.E (weightTreatSummand p i) := by have hcongr : ∀ z, BhatTreat p z = (1 / n) * ∑ i : U, weightTreatSummand p i z := by intro z; rw [BhatTreat, hn]; ring rw [D.E_congr hcongr, D.E_const_mul, D.E_sum] have h2 : ∀ i : U, D.E (weightTreatSummand p i) = 1 := by intro i have hc : ∀ z, weightTreatSummand p i z = (1 / p i) * (if z i then (1 : ℝ) else 0) := by intro z; rw [weightTreatSummand]; ring rw [D.E_congr hc, D.E_const_mul] have : D.E (fun z => if z i then (1 : ℝ) else 0) = p i := by rw [hD]; exact bernoulliDesign_E_treat p hp0 hp1 i rw [this]; field_simp [hp0' i] rw [h1] simp only [h2, Finset.sum_const, Finset.card_univ, nsmul_eq_mul, mul_one] rw [← hn]; field_simp
    Causalean.Experimentation.UnknownInterference.E_BhatTreat · Causalean/Experimentation/UnknownInterference/Hajek.lean:95
  • E_BhatCtrl theorem — With nonzero control propensities and a nonempty population, the control weight average has mean exactly one: E[B̂₀] = 1.
    p :
    U → ℝ
    hp0 :
    ∀ i, 0 ≤ p i
    hp1 :
    ∀ i, p i ≤ 1
    hp1' :
    ∀ i, (1 : ℝ) - p i ≠ 0
    hcard :
    1 ≤ card U
    (bernoulliDesign p hp0 hp1).E (BhatCtrl p) = 1
    Proof (Lean source)
    theorem E_BhatCtrl (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (hp1' : ∀ i, (1 : ℝ) - p i ≠ 0) (hcard : 1 ≤ Fintype.card U) : (bernoulliDesign p hp0 hp1).E (BhatCtrl p) = 1 := by set D := bernoulliDesign p hp0 hp1 with hD set n : ℝ := (Fintype.card U : ℝ) with hn have hn0 : n ≠ 0 := by rw [hn]; exact_mod_cast Nat.one_le_iff_ne_zero.mp hcard have h1 : D.E (BhatCtrl p) = (1 / n) * ∑ i : U, D.E (weightCtrlSummand p i) := by have hcongr : ∀ z, BhatCtrl p z = (1 / n) * ∑ i : U, weightCtrlSummand p i z := by intro z; rw [BhatCtrl, hn]; ring rw [D.E_congr hcongr, D.E_const_mul, D.E_sum] have h2 : ∀ i : U, D.E (weightCtrlSummand p i) = 1 := by intro i have hc : ∀ z, weightCtrlSummand p i z = (1 / (1 - p i)) * (if z i then (0 : ℝ) else 1) := by intro z; rw [weightCtrlSummand]; ring rw [D.E_congr hc, D.E_const_mul] have : D.E (fun z => if z i then (0 : ℝ) else 1) = 1 - p i := by rw [hD]; exact bernoulliDesign_E_ctrl p hp0 hp1 i rw [this]; field_simp [hp1' i] rw [h1] simp only [h2, Finset.sum_const, Finset.card_univ, nsmul_eq_mul, mul_one] rw [← hn]; field_simp
    Causalean.Experimentation.UnknownInterference.E_BhatCtrl · Causalean/Experimentation/UnknownInterference/Hajek.lean:120
  • var_AhatTreat_le theorem — Variance bound for the treated numerator average: Var(Â₁) ≤ k⁴·d̄/n (same disjoint-block argument as the HT estimator).
    p :
    U → ℝ
    hp0 :
    ∀ i, 0 ≤ p i
    hp1 :
    ∀ i, p i ≤ 1
    y :
    U → (U → Bool) → ℝ
    k :
    hk :
    1 ≤ k
    hcard :
    1 ≤ Fintype.card U
    hplo :
    ∀ i, k⁻¹ ≤ p i
    hmom :
    ∀ i, (bernoulliDesign p hp0 hp1).E (fun z => (y i z) ^ 2) ≤ k ^ 2
    (bernoulliDesign p hp0 hp1).Var (AhatTreat p y) ≤ k ^ 4 * dbar y / (Fintype.card U : ℝ)
    Proof (Lean source)
    theorem var_AhatTreat_le (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (y : U → (U → Bool) → ℝ) (k : ℝ) (hk : 1 ≤ k) (hcard : 1 ≤ Fintype.card U) (hplo : ∀ i, k⁻¹ ≤ p i) (hmom : ∀ i, (bernoulliDesign p hp0 hp1).E (fun z => (y i z) ^ 2) ≤ k ^ 2) : (bernoulliDesign p hp0 hp1).Var (AhatTreat p y) ≤ k ^ 4 * dbar y / (Fintype.card U : ℝ) := by classical set D := bernoulliDesign p hp0 hp1 with hD set n : ℝ := (Fintype.card U : ℝ) with hn have hn0 : (0 : ℝ) < n := by rw [hn]; exact_mod_cast lt_of_lt_of_le zero_lt_one hcard have hcov : ∀ i j, D.Cov (htTreatSummand p y i) (htTreatSummand p y j) ≤ (if InterfDep y i j then (k ^ 4 : ℝ) else 0) := by intro i j by_cases hdep : InterfDep y i j · rw [if_pos hdep] have hVsub : 0 ≤ D.Var (fun z => htTreatSummand p y i z - htTreatSummand p y j z) := Var_nonneg D _ rw [D.Var_sub] at hVsub have hVi : D.Var (htTreatSummand p y i) ≤ k ^ 4 := var_htTreatSummand_le p hp0 hp1 y k hk hplo hmom i have hVj : D.Var (htTreatSummand p y j) ≤ k ^ 4 := var_htTreatSummand_le p hp0 hp1 y k hk hplo hmom j linarith · rw [if_neg hdep] exact le_of_eq (cov_htTreatSummand_zero p hp0 hp1 y hdep) have hEstEq : AhatTreat p y = fun z => n⁻¹ * ∑ i : U, (1 : ℝ) * htTreatSummand p y i z := by funext z; unfold AhatTreat; rw [hn, div_eq_inv_mul]; congr 1 exact Finset.sum_congr rfl (fun i _ => (one_mul _).symm) have hVarEst : D.Var (AhatTreat p y) = (n⁻¹) ^ 2 * ∑ i : U, ∑ j : U, D.Cov (htTreatSummand p y i) (htTreatSummand p y j) := by rw [hEstEq, D.Var_const_mul, D.Var_linear_comb univ (fun _ => (1 : ℝ)) (htTreatSummand p y)] congr 1 refine Finset.sum_congr rfl (fun i _ => Finset.sum_congr rfl (fun j _ => ?_)) rw [one_mul, one_mul] have hsumle : (∑ i : U, ∑ j : U, D.Cov (htTreatSummand p y i) (htTreatSummand p y j)) ≤ k ^ 4 * dbarCount y := by have hstep : (∑ i : U, ∑ j : U, D.Cov (htTreatSummand p y i) (htTreatSummand p y j)) ≤ ∑ i : U, ∑ j : U, (if InterfDep y i j then (k ^ 4 : ℝ) else 0) := Finset.sum_le_sum (fun i _ => Finset.sum_le_sum (fun j _ => hcov i j)) refine le_trans hstep ?_ rw [dbarCount, Finset.mul_sum] refine Finset.sum_le_sum (fun i _ => ?_) rw [Finset.mul_sum] refine Finset.sum_le_sum (fun j _ => ?_) by_cases hdep : InterfDep y i j <;> simp [hdep] rw [hVarEst] have hninv2 : (0 : ℝ) ≤ (n⁻¹) ^ 2 := sq_nonneg _ calc (n⁻¹) ^ 2 * ∑ i : U, ∑ j : U, D.Cov (htTreatSummand p y i) (htTreatSummand p y j) ≤ (n⁻¹) ^ 2 * (k ^ 4 * dbarCount y) := mul_le_mul_of_nonneg_left hsumle hninv2 _ = k ^ 4 * dbar y / n := by rw [dbar, hn]; ring
    Causalean.Experimentation.UnknownInterference.var_AhatTreat_le · Causalean/Experimentation/UnknownInterference/Hajek.lean:399
  • var_AhatCtrl_le theorem — Variance bound for the control numerator average: Var(Â₀) ≤ k⁴·d̄/n.
    p :
    U → ℝ
    hp0 :
    ∀ i, 0 ≤ p i
    hp1 :
    ∀ i, p i ≤ 1
    y :
    U → (U → Bool) → ℝ
    k :
    hk :
    1 ≤ k
    hcard :
    1 ≤ Fintype.card U
    hphi :
    ∀ i, p i ≤ 1 - k⁻¹
    hmom :
    ∀ i, (bernoulliDesign p hp0 hp1).E (fun z => (y i z) ^ 2) ≤ k ^ 2
    (bernoulliDesign p hp0 hp1).Var (AhatCtrl p y) ≤ k ^ 4 * dbar y / (Fintype.card U : ℝ)
    Proof (Lean source)
    theorem var_AhatCtrl_le (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (y : U → (U → Bool) → ℝ) (k : ℝ) (hk : 1 ≤ k) (hcard : 1 ≤ Fintype.card U) (hphi : ∀ i, p i ≤ 1 - k⁻¹) (hmom : ∀ i, (bernoulliDesign p hp0 hp1).E (fun z => (y i z) ^ 2) ≤ k ^ 2) : (bernoulliDesign p hp0 hp1).Var (AhatCtrl p y) ≤ k ^ 4 * dbar y / (Fintype.card U : ℝ) := by classical set D := bernoulliDesign p hp0 hp1 with hD set n : ℝ := (Fintype.card U : ℝ) with hn have hn0 : (0 : ℝ) < n := by rw [hn]; exact_mod_cast lt_of_lt_of_le zero_lt_one hcard have hcov : ∀ i j, D.Cov (htCtrlSummand p y i) (htCtrlSummand p y j) ≤ (if InterfDep y i j then (k ^ 4 : ℝ) else 0) := by intro i j by_cases hdep : InterfDep y i j · rw [if_pos hdep] have hVsub : 0 ≤ D.Var (fun z => htCtrlSummand p y i z - htCtrlSummand p y j z) := Var_nonneg D _ rw [D.Var_sub] at hVsub have hVi : D.Var (htCtrlSummand p y i) ≤ k ^ 4 := var_htCtrlSummand_le p hp0 hp1 y k hk hphi hmom i have hVj : D.Var (htCtrlSummand p y j) ≤ k ^ 4 := var_htCtrlSummand_le p hp0 hp1 y k hk hphi hmom j linarith · rw [if_neg hdep] exact le_of_eq (cov_htCtrlSummand_zero p hp0 hp1 y hdep) have hEstEq : AhatCtrl p y = fun z => n⁻¹ * ∑ i : U, (1 : ℝ) * htCtrlSummand p y i z := by funext z; unfold AhatCtrl; rw [hn, div_eq_inv_mul]; congr 1 exact Finset.sum_congr rfl (fun i _ => (one_mul _).symm) have hVarEst : D.Var (AhatCtrl p y) = (n⁻¹) ^ 2 * ∑ i : U, ∑ j : U, D.Cov (htCtrlSummand p y i) (htCtrlSummand p y j) := by rw [hEstEq, D.Var_const_mul, D.Var_linear_comb univ (fun _ => (1:ℝ)) (htCtrlSummand p y)] congr 1 refine Finset.sum_congr rfl (fun i _ => Finset.sum_congr rfl (fun j _ => ?_)) rw [one_mul, one_mul] have hsumle : (∑ i : U, ∑ j : U, D.Cov (htCtrlSummand p y i) (htCtrlSummand p y j)) ≤ k ^ 4 * dbarCount y := by have hstep : (∑ i : U, ∑ j : U, D.Cov (htCtrlSummand p y i) (htCtrlSummand p y j)) ≤ ∑ i : U, ∑ j : U, (if InterfDep y i j then (k ^ 4 : ℝ) else 0) := Finset.sum_le_sum (fun i _ => Finset.sum_le_sum (fun j _ => hcov i j)) refine le_trans hstep ?_ rw [dbarCount, Finset.mul_sum] refine Finset.sum_le_sum (fun i _ => ?_) rw [Finset.mul_sum] refine Finset.sum_le_sum (fun j _ => ?_) by_cases hdep : InterfDep y i j <;> simp [hdep] rw [hVarEst] have hninv2 : (0 : ℝ) ≤ (n⁻¹) ^ 2 := sq_nonneg _ calc (n⁻¹) ^ 2 * ∑ i : U, ∑ j : U, D.Cov (htCtrlSummand p y i) (htCtrlSummand p y j) ≤ (n⁻¹) ^ 2 * (k ^ 4 * dbarCount y) := mul_le_mul_of_nonneg_left hsumle hninv2 _ = k ^ 4 * dbar y / n := by rw [dbar, hn]; ring
    Causalean.Experimentation.UnknownInterference.var_AhatCtrl_le · Causalean/Experimentation/UnknownInterference/Hajek.lean:453
  • var_BhatTreat_le theorem — Variance bound for the treated weight average: Var(B̂₁) ≤ k²/n (single-coordinate independence — the weight summands Zᵢ/pᵢ depend on disjoint singletons).
    p :
    U → ℝ
    hp0 :
    ∀ i, 0 ≤ p i
    hp1 :
    ∀ i, p i ≤ 1
    k :
    hk :
    1 ≤ k
    hcard :
    1 ≤ Fintype.card U
    hplo :
    ∀ i, k⁻¹ ≤ p i
    (bernoulliDesign p hp0 hp1).Var (BhatTreat p) ≤ k ^ 2 / (Fintype.card U : ℝ)
    Proof (Lean source)
    theorem var_BhatTreat_le (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (k : ℝ) (hk : 1 ≤ k) (hcard : 1 ≤ Fintype.card U) (hplo : ∀ i, k⁻¹ ≤ p i) : (bernoulliDesign p hp0 hp1).Var (BhatTreat p) ≤ k ^ 2 / (Fintype.card U : ℝ) := by set n : ℝ := (Fintype.card U : ℝ) with hn have hn0 : (0 : ℝ) < n := by rw [hn]; exact_mod_cast lt_of_lt_of_le zero_lt_one hcard have hk0 : (0 : ℝ) < k := lt_of_lt_of_le zero_lt_one hk have hkinv0 : (0 : ℝ) < k⁻¹ := inv_pos.mpr hk0 -- single-coordinate function `g_i b = (if b then 1 else 0)/p i` set g : U → Bool → ℝ := fun i b => (if b then (1 : ℝ) else 0) / p i with hg -- `BhatTreat = fun z => ∑ i, (n⁻¹) * g i (z i)` have hBeq : BhatTreat p = fun z => ∑ i : U, n⁻¹ * g i (z i) := by funext z; unfold BhatTreat weightTreatSummand rw [hn, Finset.sum_div] refine Finset.sum_congr rfl (fun i _ => ?_) rw [hg]; ring -- per-coordinate variance bound `Var(g i) ≤ k²` have hVcoord : ∀ i, (coinDesign (p i) (hp0 i) (hp1 i)).Var (g i) ≤ k ^ 2 := by intro i have hpi0 : (0 : ℝ) < p i := lt_of_lt_of_le hkinv0 (hplo i) have hrecp : 1 / p i ≤ k := by rw [div_le_iff₀ hpi0] nlinarith [mul_le_mul_of_nonneg_right (hplo i) (le_of_lt hk0), inv_mul_cancel₀ (ne_of_gt hk0)] have hEsq : (coinDesign (p i) (hp0 i) (hp1 i)).E (fun b => (g i b) ^ 2) = 1 / p i := by have h0 : p i ≠ 0 := ne_of_gt hpi0 rw [coinDesign_E]; simp only [hg]; norm_num; field_simp have hVle : (coinDesign (p i) (hp0 i) (hp1 i)).Var (g i) ≤ (coinDesign (p i) (hp0 i) (hp1 i)).E (fun b => (g i b) ^ 2) := by rw [(coinDesign (p i) (hp0 i) (hp1 i)).Var_eq] linarith [sq_nonneg ((coinDesign (p i) (hp0 i) (hp1 i)).E (g i))] have hk2 : (1 : ℝ) / p i ≤ k ^ 2 := by nlinarith [hrecp, hk] linarith [le_trans hVle (le_of_eq hEsq)] -- apply the product-design linear-combination variance identity rw [hBeq] unfold bernoulliDesign rw [FiniteDesign.Var_prod_linear_comb (fun i => coinDesign (p i) (hp0 i) (hp1 i)) (fun _ => n⁻¹) g] -- `∑ i, (n⁻¹)² · Var(g i) ≤ ∑ i, (n⁻¹)² · k² = n · (n⁻¹)² · k² = k²/n` have hninv2 : (0 : ℝ) ≤ (n⁻¹) ^ 2 := sq_nonneg _ have hstep : (∑ i : U, (n⁻¹) ^ 2 * (coinDesign (p i) (hp0 i) (hp1 i)).Var (g i)) ≤ ∑ _i : U, (n⁻¹) ^ 2 * k ^ 2 := Finset.sum_le_sum (fun i _ => mul_le_mul_of_nonneg_left (hVcoord i) hninv2) refine le_trans hstep ?_ rw [Finset.sum_const, Finset.card_univ, nsmul_eq_mul, ← hn] rw [show (n : ℝ) * ((n⁻¹) ^ 2 * k ^ 2) = (n * n⁻¹) * (n⁻¹ * k ^ 2) by ring] rw [mul_inv_cancel₀ (ne_of_gt hn0), one_mul, inv_mul_eq_div]
    Causalean.Experimentation.UnknownInterference.var_BhatTreat_le · Causalean/Experimentation/UnknownInterference/Hajek.lean:505
  • var_BhatCtrl_le theorem — Variance bound for the control weight average: Var(B̂₀) ≤ k²/n.
    p :
    U → ℝ
    hp0 :
    ∀ i, 0 ≤ p i
    hp1 :
    ∀ i, p i ≤ 1
    k :
    hk :
    1 ≤ k
    hcard :
    1 ≤ Fintype.card U
    hphi :
    ∀ i, p i ≤ 1 - k⁻¹
    (bernoulliDesign p hp0 hp1).Var (BhatCtrl p) ≤ k ^ 2 / (Fintype.card U : ℝ)
    Proof (Lean source)
    theorem var_BhatCtrl_le (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (k : ℝ) (hk : 1 ≤ k) (hcard : 1 ≤ Fintype.card U) (hphi : ∀ i, p i ≤ 1 - k⁻¹) : (bernoulliDesign p hp0 hp1).Var (BhatCtrl p) ≤ k ^ 2 / (Fintype.card U : ℝ) := by set n : ℝ := (Fintype.card U : ℝ) with hn have hn0 : (0 : ℝ) < n := by rw [hn]; exact_mod_cast lt_of_lt_of_le zero_lt_one hcard have hk0 : (0 : ℝ) < k := lt_of_lt_of_le zero_lt_one hk have hkinv0 : (0 : ℝ) < k⁻¹ := inv_pos.mpr hk0 -- single-coordinate function `g_i b = (if b then 0 else 1)/(1 - p i)` set g : U → Bool → ℝ := fun i b => (if b then (0 : ℝ) else 1) / (1 - p i) with hg have hBeq : BhatCtrl p = fun z => ∑ i : U, n⁻¹ * g i (z i) := by funext z; unfold BhatCtrl weightCtrlSummand rw [hn, Finset.sum_div] refine Finset.sum_congr rfl (fun i _ => ?_) rw [hg]; ring have hVcoord : ∀ i, (coinDesign (p i) (hp0 i) (hp1 i)).Var (g i) ≤ k ^ 2 := by intro i have hpi1 : (0 : ℝ) < 1 - p i := lt_of_lt_of_le hkinv0 (by linarith [hphi i]) have hrecq : 1 / (1 - p i) ≤ k := by rw [div_le_iff₀ hpi1] nlinarith [mul_le_mul_of_nonneg_right (by linarith [hphi i] : k⁻¹ ≤ 1 - p i) (le_of_lt hk0), inv_mul_cancel₀ (ne_of_gt hk0)] have hEsq : (coinDesign (p i) (hp0 i) (hp1 i)).E (fun b => (g i b) ^ 2) = 1 / (1 - p i) := by have h1 : (1 : ℝ) - p i ≠ 0 := ne_of_gt hpi1 rw [coinDesign_E]; simp only [hg]; norm_num; field_simp have hVle : (coinDesign (p i) (hp0 i) (hp1 i)).Var (g i) ≤ (coinDesign (p i) (hp0 i) (hp1 i)).E (fun b => (g i b) ^ 2) := by rw [(coinDesign (p i) (hp0 i) (hp1 i)).Var_eq] linarith [sq_nonneg ((coinDesign (p i) (hp0 i) (hp1 i)).E (g i))] have hk2 : (1 : ℝ) / (1 - p i) ≤ k ^ 2 := by nlinarith [hrecq, hk] linarith [le_trans hVle (le_of_eq hEsq)] rw [hBeq] unfold bernoulliDesign rw [FiniteDesign.Var_prod_linear_comb (fun i => coinDesign (p i) (hp0 i) (hp1 i)) (fun _ => n⁻¹) g] have hninv2 : (0 : ℝ) ≤ (n⁻¹) ^ 2 := sq_nonneg _ have hstep : (∑ i : U, (n⁻¹) ^ 2 * (coinDesign (p i) (hp0 i) (hp1 i)).Var (g i)) ≤ ∑ _i : U, (n⁻¹) ^ 2 * k ^ 2 := Finset.sum_le_sum (fun i _ => mul_le_mul_of_nonneg_left (hVcoord i) hninv2) refine le_trans hstep ?_ rw [Finset.sum_const, Finset.card_univ, nsmul_eq_mul, ← hn] rw [show (n : ℝ) * ((n⁻¹) ^ 2 * k ^ 2) = (n * n⁻¹) * (n⁻¹ * k ^ 2) by ring] rw [mul_inv_cancel₀ (ne_of_gt hn0), one_mul, inv_mul_eq_div]
    Causalean.Experimentation.UnknownInterference.var_BhatCtrl_le · Causalean/Experimentation/UnknownInterference/Hajek.lean:554
  • abs_E_AhatTreat_le theorem — The treated numerator mean is the average treated potential outcome, uniformly bounded by k via the potential-outcome moment bound (Assumption C).
    p :
    U → ℝ
    hp0 :
    ∀ i, 0 ≤ p i
    hp1 :
    ∀ i, p i ≤ 1
    hp0' :
    ∀ i, p i ≠ 0
    y :
    U → (U → Bool) → ℝ
    k :
    hk :
    1 ≤ k
    hcard :
    1 ≤ card U
    hpo :
    ∀ i, (bernoulliDesign p hp0 hp1).E (fun z => |y i (update z i true)|) ≤ k
    |(bernoulliDesign p hp0 hp1).E (AhatTreat p y)| ≤ k
    Proof (Lean source)
    theorem abs_E_AhatTreat_le (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (hp0' : ∀ i, p i ≠ 0) (y : U → (U → Bool) → ℝ) (k : ℝ) (hk : 1 ≤ k) (hcard : 1 ≤ Fintype.card U) (hpo : ∀ i, (bernoulliDesign p hp0 hp1).E (fun z => |y i (update z i true)|) ≤ k) : |(bernoulliDesign p hp0 hp1).E (AhatTreat p y)| ≤ k := by set D := bernoulliDesign p hp0 hp1 with hD set n : ℝ := (Fintype.card U : ℝ) with hn have hn0 : (0 : ℝ) < n := by rw [hn]; exact_mod_cast lt_of_lt_of_le Nat.zero_lt_one hcard -- `E[Â₁] = (1/n) * ∑ i E[htTreatSummand i]`. have h1 : D.E (AhatTreat p y) = (1 / n) * ∑ i : U, D.E (htTreatSummand p y i) := by have hcongr : ∀ z, AhatTreat p y z = (1 / n) * ∑ i : U, htTreatSummand p y i z := by intro z; rw [AhatTreat, hn]; ring rw [D.E_congr hcongr, D.E_const_mul, D.E_sum] -- Each summand's expectation is bounded by `k`. have hbound : ∀ i : U, |D.E (htTreatSummand p y i)| ≤ k := by intro i rw [E_htTreatSummand p hp0 hp1 hp0' y i] exact le_trans (abs_E_le_E_abs D _) (hpo i) rw [h1, abs_mul] have hpos : |1 / n| = 1 / n := abs_of_pos (by positivity) rw [hpos] calc (1 / n) * |∑ i : U, D.E (htTreatSummand p y i)| ≤ (1 / n) * ∑ i : U, |D.E (htTreatSummand p y i)| := mul_le_mul_of_nonneg_left (Finset.abs_sum_le_sum_abs _ _) (by positivity) _ ≤ (1 / n) * ∑ i : U, k := mul_le_mul_of_nonneg_left (Finset.sum_le_sum (fun i _ => hbound i)) (by positivity) _ = k := by rw [Finset.sum_const, Finset.card_univ, nsmul_eq_mul, ← hn] field_simp
    Causalean.Experimentation.UnknownInterference.abs_E_AhatTreat_le · Causalean/Experimentation/UnknownInterference/Hajek.lean:599
  • abs_E_AhatCtrl_le theorem — The control numerator mean is the average control potential outcome, uniformly bounded by k.
    p :
    U → ℝ
    hp0 :
    ∀ i, 0 ≤ p i
    hp1 :
    ∀ i, p i ≤ 1
    hp1' :
    ∀ i, (1 : ℝ) - p i ≠ 0
    y :
    U → (U → Bool) → ℝ
    k :
    hk :
    1 ≤ k
    hcard :
    1 ≤ card U
    hpo :
    ∀ i, (bernoulliDesign p hp0 hp1).E (fun z => |y i (update z i false)|) ≤ k
    |(bernoulliDesign p hp0 hp1).E (AhatCtrl p y)| ≤ k
    Proof (Lean source)
    theorem abs_E_AhatCtrl_le (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (hp1' : ∀ i, (1 : ℝ) - p i ≠ 0) (y : U → (U → Bool) → ℝ) (k : ℝ) (hk : 1 ≤ k) (hcard : 1 ≤ Fintype.card U) (hpo : ∀ i, (bernoulliDesign p hp0 hp1).E (fun z => |y i (update z i false)|) ≤ k) : |(bernoulliDesign p hp0 hp1).E (AhatCtrl p y)| ≤ k := by set D := bernoulliDesign p hp0 hp1 with hD set n : ℝ := (Fintype.card U : ℝ) with hn have hn0 : (0 : ℝ) < n := by rw [hn]; exact_mod_cast Nat.lt_of_lt_of_le Nat.zero_lt_one hcard have h1 : D.E (AhatCtrl p y) = (1 / n) * ∑ i : U, D.E (htCtrlSummand p y i) := by have hcongr : ∀ z, AhatCtrl p y z = (1 / n) * ∑ i : U, htCtrlSummand p y i z := by intro z; rw [AhatCtrl, hn]; ring rw [D.E_congr hcongr, D.E_const_mul, D.E_sum] have hbound : ∀ i : U, |D.E (htCtrlSummand p y i)| ≤ k := by intro i rw [E_htCtrlSummand p hp0 hp1 hp1' y i] exact le_trans (abs_E_le_E_abs D _) (hpo i) rw [h1, abs_mul] have hpos : |1 / n| = 1 / n := abs_of_pos (by positivity) rw [hpos] calc (1 / n) * |∑ i : U, D.E (htCtrlSummand p y i)| ≤ (1 / n) * ∑ i : U, |D.E (htCtrlSummand p y i)| := mul_le_mul_of_nonneg_left (Finset.abs_sum_le_sum_abs _ _) (by positivity) _ ≤ (1 / n) * ∑ i : U, k := mul_le_mul_of_nonneg_left (Finset.sum_le_sum (fun i _ => hbound i)) (by positivity) _ = k := by rw [Finset.sum_const, Finset.card_univ, nsmul_eq_mul, ← hn] field_simp
    Causalean.Experimentation.UnknownInterference.abs_E_AhatCtrl_le · Causalean/Experimentation/UnknownInterference/Hajek.lean:632
  • E_AhatTreat_sub_E_AhatCtrl theorem — The difference of the numerator means is EATE: E[Â₁] − E[Â₀] = EATE (the HT estimator is Â₁ − Â₀, and it is unbiased).
    p :
    U → ℝ
    hp0 :
    ∀ i, 0 ≤ p i
    hp1 :
    ∀ i, p i ≤ 1
    hp0' :
    ∀ i, p i ≠ 0
    hp1' :
    ∀ i, (1 : ℝ) - p i ≠ 0
    y :
    U → (U → Bool) → ℝ
    (bernoulliDesign p hp0 hp1).E (AhatTreat p y)
    - (bernoulliDesign p hp0 hp1).E (AhatCtrl p y)
    = EATE (bernoulliDesign p hp0 hp1) y
    Proof (Lean source)
    theorem E_AhatTreat_sub_E_AhatCtrl (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (hp0' : ∀ i, p i ≠ 0) (hp1' : ∀ i, (1 : ℝ) - p i ≠ 0) (y : U → (U → Bool) → ℝ) : (bernoulliDesign p hp0 hp1).E (AhatTreat p y) - (bernoulliDesign p hp0 hp1).E (AhatCtrl p y) = EATE (bernoulliDesign p hp0 hp1) y := by set D := bernoulliDesign p hp0 hp1 with hD rw [← D.E_sub] -- Pointwise `AhatTreat - AhatCtrl = htEst`. have hpt : ∀ z, AhatTreat p y z - AhatCtrl p y z = htEst p y z := by intro z rw [AhatTreat, AhatCtrl, htEst, ← sub_div] congr 1 rw [← Finset.sum_sub_distrib] refine Finset.sum_congr rfl (fun i _ => ?_) rw [htSummand, htTreatSummand, htCtrlSummand] rw [D.E_congr hpt] rw [hD] exact htEst_unbiased p hp0 hp1 hp0' hp1' y
    Causalean.Experimentation.UnknownInterference.E_AhatTreat_sub_E_AhatCtrl · Causalean/Experimentation/UnknownInterference/Hajek.lean:663
Unbiased 2 core · 0 supporting Bernoulli Horvitz-Thompson estimators are exactly unbiased for the expected average treatment effect even when outcomes may depend on other units' assignments. ★ E_htSummand★ htEst_unbiased

Unbiasedness under unknown interference

Bernoulli Horvitz-Thompson estimators are exactly unbiased for the expected average treatment effect even when outcomes may depend on other units' assignments.

The per-unit theorem E_htSummand shows that the ith Horvitz-Thompson summand has expectation equal to the assignment-conditional treatment effect tau y i. Its proof uses product-design block independence between unit i's own treatment and the remaining assignments that determine y_i(1; Z_{-i}) or y_i(0; Z_{-i}), plus the Bernoulli marginal identities from Bernoulli. Summing these identities gives htEst_unbiased, the exact equality E[htEst] = EATE.

theorem E_htSummand reviewed
Causalean.Experimentation.UnknownInterference

Per-unit unbiasedness. Under a Bernoulli design in which every unit's treatment probability lies in [0,1] and is neither exactly zero nor exactly one, so both the treatment and control propensities are nonzero, the i-th Horvitz–Thompson summand has the same expectation as unit i's assignment-conditional treatment effect τ_i.

Formal statement
p :
U → ℝ
hp0 :
∀ i, 0 ≤ p i
hp1 :
∀ i, p i ≤ 1
hp0' :
∀ i, p i ≠ 0
hp1' :
∀ i, (1 : ℝ) - p i ≠ 0
y :
U → (U → Bool) → ℝ
i :
U
(bernoulliDesign p hp0 hp1).E (htSummand p y i) = (bernoulliDesign p hp0 hp1).E (tau y i)
Proof (Lean source)
theorem E_htSummand (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (hp0' : ∀ i, p i ≠ 0) (hp1' : ∀ i, (1 : ℝ) - p i ≠ 0) (y : U → (U → Bool) → ℝ) (i : U) : (bernoulliDesign p hp0 hp1).E (htSummand p y i) = (bernoulliDesign p hp0 hp1).E (tau y i) := by classical letI : MeasurableSpace Bool := ⊤ letI : MeasurableSingletonClass Bool := ⟨fun _ => trivial⟩ set D := bernoulliDesign p hp0 hp1 with hD -- The treated potential outcome as a function of the full assignment. set hT : (U → Bool) → ℝ := fun z => y i (update z i true) with hhT set hC : (U → Bool) → ℝ := fun z => y i (update z i false) with hhC -- Treatment-term expectation equals `E[hT]`. have htreat : D.E (fun z => (if z i then (1 : ℝ) else 0) * y i z / p i) = D.E hT := by -- Pointwise rewrite `y i z` to `hT z` against the indicator. have hpt : ∀ z, (if z i then (1 : ℝ) else 0) * y i z / p i = (1 / p i) * ((if z i then (1 : ℝ) else 0) * hT z) := by intro z by_cases hz : z i · have : update z i true = z := by funext x; by_cases hx : x = i · subst hx; rw [Function.update_self]; exact hz.symm · rw [Function.update_of_ne hx] simp only [hz, if_pos, hhT, this] field_simp · simp only [hz, hhT] simp rw [D.E_congr hpt, D.E_const_mul] -- Factor `E[(if z i then 1 else 0) * hT z]` via block independence. have hblock : D.E (fun z => (if z i then (1 : ℝ) else 0) * hT z) = D.E (fun z => if z i then (1 : ℝ) else 0) * D.E hT := by rw [hD] unfold bernoulliDesign refine FiniteDesign.E_prod_block_mul _ {i} (fun z => if z i then (1 : ℝ) else 0) hT ?_ ?_ · intro w w' hww have hwi : w i = w' i := hww i (mem_singleton_self i) change (if w i then (1 : ℝ) else 0) = (if w' i then (1 : ℝ) else 0) rw [hwi] · intro w w' hww change y i (update w i true) = y i (update w' i true) congr 1 funext x by_cases hx : x = i · subst hx; rw [Function.update_self, Function.update_self] · rw [Function.update_of_ne hx, Function.update_of_ne hx] exact hww x (by simp [mem_singleton, hx]) rw [hblock] have hEtreat : D.E (fun z => if z i then (1 : ℝ) else 0) = p i := by rw [hD]; exact bernoulliDesign_E_treat p hp0 hp1 i rw [hEtreat] field_simp [hp0' i] -- Control-term expectation equals `E[hC]`. have hctrl : D.E (fun z => (if z i then (0 : ℝ) else 1) * y i z / (1 - p i)) = D.E hC := by have hpt : ∀ z, (if z i then (0 : ℝ) else 1) * y i z / (1 - p i) = (1 / (1 - p i)) * ((if z i then (0 : ℝ) else 1) * hC z) := by intro z by_cases hz : z i · simp only [hz, if_pos, hhC] simp · have : update z i false = z := by funext x; by_cases hx : x = i · subst hx; rw [Function.update_self]; simpa using hz · rw [Function.update_of_ne hx] simp only [hz, hhC, this] field_simp rw [D.E_congr hpt, D.E_const_mul] have hblock : D.E (fun z => (if z i then (0 : ℝ) else 1) * hC z) = D.E (fun z => if z i then (0 : ℝ) else 1) * D.E hC := by rw [hD] unfold bernoulliDesign refine FiniteDesign.E_prod_block_mul _ {i} (fun z => if z i then (0 : ℝ) else 1) hC ?_ ?_ · intro w w' hww have hwi : w i = w' i := hww i (mem_singleton_self i) change (if w i then (0 : ℝ) else 1) = (if w' i then (0 : ℝ) else 1) rw [hwi] · intro w w' hww change y i (update w i false) = y i (update w' i false) congr 1 funext x by_cases hx : x = i · subst hx; rw [Function.update_self, Function.update_self] · rw [Function.update_of_ne hx, Function.update_of_ne hx] exact hww x (by simp [mem_singleton, hx]) rw [hblock] have hEctrl : D.E (fun z => if z i then (0 : ℝ) else 1) = 1 - p i := by rw [hD]; exact bernoulliDesign_E_ctrl p hp0 hp1 i rw [hEctrl] field_simp [hp1' i] -- Assemble: `E[htSummand] = E[hT] - E[hC] = E[tau]`. have hsplit : D.E (htSummand p y i) = D.E (fun z => (if z i then (1 : ℝ) else 0) * y i z / p i) - D.E (fun z => (if z i then (0 : ℝ) else 1) * y i z / (1 - p i)) := by rw [← D.E_sub]; rfl rw [hsplit, htreat, hctrl, ← D.E_sub] rfl
Causalean.Experimentation.UnknownInterference.E_htSummand · Causalean/Experimentation/UnknownInterference/Unbiased.lean:49 · uses E , bernoulliDesign , htSummand , tau
theorem htEst_unbiased reviewed
Causalean.Experimentation.UnknownInterference

Horvitz–Thompson unbiasedness for EATE (Sävje–Aronow–Hudgens 2021). Under a Bernoulli design in which every unit's treatment probability lies in [0,1] and is neither exactly zero nor exactly one, so both the treatment and control propensities are nonzero, the Horvitz–Thompson estimator is exactly unbiased for the expected average treatment effect.

Formal statement
p :
U → ℝ
hp0 :
∀ i, 0 ≤ p i
hp1 :
∀ i, p i ≤ 1
hp0' :
∀ i, p i ≠ 0
hp1' :
∀ i, (1 : ℝ) - p i ≠ 0
y :
U → (U → Bool) → ℝ
(bernoulliDesign p hp0 hp1).E (htEst p y) = EATE (bernoulliDesign p hp0 hp1) y
Proof (Lean source)
theorem htEst_unbiased (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (hp0' : ∀ i, p i ≠ 0) (hp1' : ∀ i, (1 : ℝ) - p i ≠ 0) (y : U → (U → Bool) → ℝ) : (bernoulliDesign p hp0 hp1).E (htEst p y) = EATE (bernoulliDesign p hp0 hp1) y := by set D := bernoulliDesign p hp0 hp1 with hD set n : ℝ := (Fintype.card U : ℝ) with hn -- `E[htEst] = (1/n) * ∑ i E[htSummand i]`. have h1 : D.E (htEst p y) = (1 / n) * ∑ i : U, D.E (htSummand p y i) := by have hcongr : ∀ z, htEst p y z = (1 / n) * ∑ i : U, htSummand p y i z := by intro z rw [htEst] rw [hn] ring rw [D.E_congr hcongr, D.E_const_mul, D.E_sum] -- `EATE = (1/n) * ∑ i E[tau i]`. have h2 : EATE D y = (1 / n) * ∑ i : U, D.E (tau y i) := by rw [EATE] have hcongr : ∀ z, ACATE y z = (1 / n) * ∑ i : U, tau y i z := by intro z rw [ACATE, hn] ring rw [D.E_congr hcongr, D.E_const_mul, D.E_sum] rw [h1, h2] congr 1 refine Finset.sum_congr rfl (fun i _ => ?_) rw [hD] exact E_htSummand p hp0 hp1 hp0' hp1' y i
Causalean.Experimentation.UnknownInterference.htEst_unbiased · Causalean/Experimentation/UnknownInterference/Unbiased.lean:150 · uses E , EATE , bernoulliDesign , htEst
Variance­Bound 4 core · 2 supporting The Horvitz-Thompson variance is bounded by the average amount of interference dependence under Bernoulli assignment. ★ cov_htSummand_zero★ var_htSummand_le★ var_htEst_le

Variance bounds under unknown interference

The Horvitz-Thompson variance is bounded by the average amount of interference dependence under Bernoulli assignment.

This file proves the Sävje-Aronow-Hudgens finite-sample bound Var(htEst) <= k^4 * dbar / n under overlap and second-moment control. The block interferers y i records the coordinate support of the ith HT summand; htSummand_depends_on_interferers and disjoint_interferers_of_not_interfDep connect the interference graph to product-design disjoint-block independence, and cov_htSummand_zero eliminates covariance terms off that graph. The per-summand bound var_htSummand_le controls the remaining covariance terms by k^4, and the headline theorem var_htEst_le sums them over the dbarCount = n * dbar dependent ordered pairs.

def interferers reviewed
Causalean.Experimentation.UnknownInterference

The block of units that interfere with i (its own treatment included): the coordinate support of the iᵗʰ HT summand.

Definition (Lean source)
noncomputable def interferers (y : U → (U → Bool) → ℝ) (i : U) : Finset U := Finset.univ.filter (fun ℓ => Interferes y ℓ i)
Causalean.Experimentation.UnknownInterference.interferers · Causalean/Experimentation/UnknownInterference/VarianceBound.lean:57
theorem cov_htSummand_zero reviewed
Causalean.Experimentation.UnknownInterference

No covariance off the interference-dependence graph. Under a Bernoulli design in which each unit i is treated independently with probability p i, where every p i lies in the unit interval, if units i and j are not interference dependent — no unit's treatment affects both units' outcomes — then their Horvitz–Thompson summands have zero covariance under this design.

Formal statement
p :
U → ℝ
hp0 :
∀ i, 0 ≤ p i
hp1 :
∀ i, p i ≤ 1
y :
U → (U → Bool) → ℝ
i j :
U
h :
¬ InterfDep y i j
(bernoulliDesign p hp0 hp1).Cov (htSummand p y i) (htSummand p y j) = 0
Proof (Lean source)
theorem cov_htSummand_zero (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (y : U → (U → Bool) → ℝ) {i j : U} (h : ¬ InterfDep y i j) : (bernoulliDesign p hp0 hp1).Cov (htSummand p y i) (htSummand p y j) = 0 := by letI : MeasurableSpace Bool := ⊤ letI : MeasurableSingletonClass Bool := ⟨fun _ => trivial⟩ unfold bernoulliDesign exact FiniteDesign.Cov_prod_disjoint_zero (fun i => coinDesign (p i) (hp0 i) (hp1 i)) (interferers y i) (interferers y j) (disjoint_interferers_of_not_interfDep y h) (htSummand p y i) (htSummand p y j) (fun z z' hzz => htSummand_depends_on_interferers p y i z z' hzz) (fun z z' hzz => htSummand_depends_on_interferers p y j z z' hzz)
Causalean.Experimentation.UnknownInterference.cov_htSummand_zero · Causalean/Experimentation/UnknownInterference/VarianceBound.lean:89 · uses Cov , InterfDep , bernoulliDesign , htSummand
theorem var_htSummand_le reviewed
Causalean.Experimentation.UnknownInterference

Per-summand variance bound. Fix a regularity constant k at least 1 and a Bernoulli design with per-unit treatment probabilities lying in the unit interval and further satisfying the overlap bounds k⁻¹ ≤ p i ≤ 1 − k⁻¹ for every unit. If the outcome function's second moment E[(y i)²] is at most for every unit under this design, then the variance of the iᵗʰ Horvitz–Thompson summand is at most k⁴.

Formal statement
p :
U → ℝ
hp0 :
∀ i, 0 ≤ p i
hp1 :
∀ i, p i ≤ 1
y :
U → (U → Bool) → ℝ
k :
hk :
1 ≤ k
hplo :
∀ i, k⁻¹ ≤ p i
hphi :
∀ i, p i ≤ 1 - k⁻¹
hmom :
∀ i, (bernoulliDesign p hp0 hp1).E (fun z => (y i z) ^ 2) ≤ k ^ 2
i :
U
(bernoulliDesign p hp0 hp1).Var (htSummand p y i) ≤ k ^ 4
Proof (Lean source)
theorem var_htSummand_le (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (y : U → (U → Bool) → ℝ) (k : ℝ) (hk : 1 ≤ k) (hplo : ∀ i, k⁻¹ ≤ p i) (hphi : ∀ i, p i ≤ 1 - k⁻¹) (hmom : ∀ i, (bernoulliDesign p hp0 hp1).E (fun z => (y i z) ^ 2) ≤ k ^ 2) (i : U) : (bernoulliDesign p hp0 hp1).Var (htSummand p y i) ≤ k ^ 4 := by set D := bernoulliDesign p hp0 hp1 with hD have hk0 : (0 : ℝ) < k := lt_of_lt_of_le zero_lt_one hk have hkinv0 : (0 : ℝ) < k⁻¹ := inv_pos.mpr hk0 have hpi0 : (0 : ℝ) < p i := lt_of_lt_of_le hkinv0 (hplo i) have hpi1 : (0 : ℝ) < 1 - p i := lt_of_lt_of_le hkinv0 (by linarith [hphi i]) -- `1/p i ≤ k` and `1/(1 - p i) ≤ k`. have hrecp : 1 / p i ≤ k := by rw [div_le_iff₀ hpi0] have := (hplo i) have hk' : k⁻¹ * k = 1 := inv_mul_cancel₀ (ne_of_gt hk0) nlinarith [mul_le_mul_of_nonneg_right (hplo i) (le_of_lt hk0)] have hrecq : 1 / (1 - p i) ≤ k := by rw [div_le_iff₀ hpi1] nlinarith [mul_le_mul_of_nonneg_right (by linarith [hphi i] : k⁻¹ ≤ 1 - p i) (le_of_lt hk0), inv_mul_cancel₀ (ne_of_gt hk0)] -- Pointwise: `(htSummand)² ≤ k² (y i)²`. have hpt : ∀ z, (htSummand p y i z) ^ 2 ≤ k ^ 2 * (y i z) ^ 2 := by intro z have habs : |htSummand p y i z| ≤ k * |y i z| := by unfold htSummand by_cases hz : z i = true · rw [if_pos hz, if_pos hz] rw [show (1 : ℝ) * y i z / p i - (0 : ℝ) * y i z / (1 - p i) = y i z / p i by ring] rw [abs_div, abs_of_pos hpi0] calc |y i z| / p i = |y i z| * (1 / p i) := by ring _ ≤ |y i z| * k := by apply mul_le_mul_of_nonneg_left hrecp (abs_nonneg _) _ = k * |y i z| := by ring · rw [if_neg hz, if_neg hz] rw [show (0 : ℝ) * y i z / p i - (1 : ℝ) * y i z / (1 - p i) = - (y i z / (1 - p i)) by ring] rw [abs_neg, abs_div, abs_of_pos hpi1] calc |y i z| / (1 - p i) = |y i z| * (1 / (1 - p i)) := by ring _ ≤ |y i z| * k := by apply mul_le_mul_of_nonneg_left hrecq (abs_nonneg _) _ = k * |y i z| := by ring have h1 : (htSummand p y i z) ^ 2 = |htSummand p y i z| ^ 2 := (sq_abs _).symm have h2 : (k * |y i z|) ^ 2 = k ^ 2 * (y i z) ^ 2 := by rw [mul_pow, sq_abs] rw [h1, ← h2] exact pow_le_pow_left₀ (abs_nonneg _) habs 2 -- `Var ≤ E[(htSummand)²] ≤ E[k² (y i)²] = k² E[(y i)²] ≤ k² · k² = k⁴`. calc D.Var (htSummand p y i) ≤ D.E (fun z => (htSummand p y i z) ^ 2) := by rw [D.Var_eq]; linarith [sq_nonneg (D.E (htSummand p y i))] _ ≤ D.E (fun z => k ^ 2 * (y i z) ^ 2) := E_mono D hpt _ = k ^ 2 * D.E (fun z => (y i z) ^ 2) := D.E_const_mul _ _ _ ≤ k ^ 2 * k ^ 2 := by apply mul_le_mul_of_nonneg_left (hmom i) (sq_nonneg k) _ = k ^ 4 := by ring
Causalean.Experimentation.UnknownInterference.var_htSummand_le · Causalean/Experimentation/UnknownInterference/VarianceBound.lean:116 · uses E , Var , bernoulliDesign , htSummand
theorem var_htEst_le reviewed
Causalean.Experimentation.UnknownInterference

The Horvitz–Thompson variance bound (Sävje–Aronow–Hudgens 2021). Fix a regularity constant k at least 1 over a nonempty finite unit population, with a Bernoulli design whose per-unit treatment probabilities lie in the unit interval and further satisfy the overlap bounds k⁻¹ ≤ p i ≤ 1 − k⁻¹ for every unit. If the outcome function's second moment E[(y i)²] is at most for every unit under this design, then the Horvitz–Thompson estimator's variance is at most k⁴ · d̄ / n, where is the average interference-dependence degree and n the number of units.

Formal statement
p :
U → ℝ
hp0 :
∀ i, 0 ≤ p i
hp1 :
∀ i, p i ≤ 1
y :
U → (U → Bool) → ℝ
k :
hk :
1 ≤ k
hcard :
1 ≤ Fintype.card U
hplo :
∀ i, k⁻¹ ≤ p i
hphi :
∀ i, p i ≤ 1 - k⁻¹
hmom :
∀ i, (bernoulliDesign p hp0 hp1).E (fun z => (y i z) ^ 2) ≤ k ^ 2
(bernoulliDesign p hp0 hp1).Var (htEst p y) ≤ k ^ 4 * dbar y / (Fintype.card U : ℝ)
Proof (Lean source)
theorem var_htEst_le (p : U → ℝ) (hp0 : ∀ i, 0 ≤ p i) (hp1 : ∀ i, p i ≤ 1) (y : U → (U → Bool) → ℝ) (k : ℝ) (hk : 1 ≤ k) (hcard : 1 ≤ Fintype.card U) (hplo : ∀ i, k⁻¹ ≤ p i) (hphi : ∀ i, p i ≤ 1 - k⁻¹) (hmom : ∀ i, (bernoulliDesign p hp0 hp1).E (fun z => (y i z) ^ 2) ≤ k ^ 2) : (bernoulliDesign p hp0 hp1).Var (htEst p y) ≤ k ^ 4 * dbar y / (Fintype.card U : ℝ) := by classical set D := bernoulliDesign p hp0 hp1 with hD set n : ℝ := (Fintype.card U : ℝ) with hn have hn0 : (0 : ℝ) < n := by rw [hn]; exact_mod_cast lt_of_lt_of_le zero_lt_one hcard have hk0 : (0 : ℝ) < k := lt_of_lt_of_le zero_lt_one hk -- Termwise covariance bound: `Cov(HTᵢ, HTⱼ) ≤ (if InterfDep then k⁴ else 0)`. have hcov : ∀ i j, D.Cov (htSummand p y i) (htSummand p y j) ≤ (if InterfDep y i j then (k ^ 4 : ℝ) else 0) := by intro i j by_cases hdep : InterfDep y i j · rw [if_pos hdep] -- `Var(X−Y) ≥ 0` gives `Cov ≤ (Var X + Var Y)/2 ≤ k⁴`. have hVsub : 0 ≤ D.Var (fun z => htSummand p y i z - htSummand p y j z) := Var_nonneg D _ rw [D.Var_sub] at hVsub have hVi : D.Var (htSummand p y i) ≤ k ^ 4 := var_htSummand_le p hp0 hp1 y k hk hplo hphi hmom i have hVj : D.Var (htSummand p y j) ≤ k ^ 4 := var_htSummand_le p hp0 hp1 y k hk hplo hphi hmom j linarith · rw [if_neg hdep] exact le_of_eq (cov_htSummand_zero p hp0 hp1 y hdep) -- `htEst = n⁻¹ * ∑ᵢ HTᵢ`, so `Var(htEst) = (n⁻¹)² Var(∑ᵢ HTᵢ)`. have hEstEq : htEst p y = fun z => n⁻¹ * ∑ i : U, (1 : ℝ) * htSummand p y i z := by funext z; unfold htEst; rw [hn, div_eq_inv_mul]; congr 1 exact Finset.sum_congr rfl (fun i _ => (one_mul _).symm) have hVarEst : D.Var (htEst p y) = (n⁻¹) ^ 2 * ∑ i : U, ∑ j : U, D.Cov (htSummand p y i) (htSummand p y j) := by rw [hEstEq, D.Var_const_mul, D.Var_linear_comb univ (fun _ => (1:ℝ)) (htSummand p y)] congr 1 refine Finset.sum_congr rfl (fun i _ => Finset.sum_congr rfl (fun j _ => ?_)) rw [one_mul, one_mul] -- Bound the double sum by `k⁴ · dbarCount`. have hsumle : (∑ i : U, ∑ j : U, D.Cov (htSummand p y i) (htSummand p y j)) ≤ k ^ 4 * dbarCount y := by have hstep : (∑ i : U, ∑ j : U, D.Cov (htSummand p y i) (htSummand p y j)) ≤ ∑ i : U, ∑ j : U, (if InterfDep y i j then (k ^ 4 : ℝ) else 0) := Finset.sum_le_sum (fun i _ => Finset.sum_le_sum (fun j _ => hcov i j)) refine le_trans hstep ?_ rw [dbarCount] rw [Finset.mul_sum] refine Finset.sum_le_sum (fun i _ => ?_) rw [Finset.mul_sum] refine Finset.sum_le_sum (fun j _ => ?_) by_cases hdep : InterfDep y i j <;> simp [hdep] -- Assemble the final bound. rw [hVarEst] have hk4 : (0 : ℝ) ≤ k ^ 4 := by positivity have hninv2 : (0 : ℝ) ≤ (n⁻¹) ^ 2 := sq_nonneg _ calc (n⁻¹) ^ 2 * ∑ i : U, ∑ j : U, D.Cov (htSummand p y i) (htSummand p y j) ≤ (n⁻¹) ^ 2 * (k ^ 4 * dbarCount y) := mul_le_mul_of_nonneg_left hsumle hninv2 _ = k ^ 4 * dbar y / n := by rw [dbar, hn] ring
Causalean.Experimentation.UnknownInterference.var_htEst_le · Causalean/Experimentation/UnknownInterference/VarianceBound.lean:178 · uses E , Var , bernoulliDesign , dbar , htEst
2 supporting declarations (lemmas, instances)