Conditional variance #
This file defines the variance of a real-valued random variable conditional to a sigma-algebra.
TODO #
Define the Lebesgue conditional variance. See GibbsMeasure for a definition of the Lebesgue conditional expectation).
noncomputable def
ProbabilityTheory.condVar
{Ω : Type u_1}
{m₀ : MeasurableSpace Ω}
(m : MeasurableSpace Ω)
(X : Ω → ℝ)
(μ : MeasureTheory.Measure Ω)
:
Ω → ℝ
Conditional variance of a real-valued random variable. It is defined as 0
if any one of the
following conditions is true:
m
is not a sub-σ-algebra ofm₀
,μ
is not σ-finite with respect tom
,X - μ[X | m]
is not square-integrable.
Equations
- ProbabilityTheory.condVar m X μ = MeasureTheory.condExp m μ ((X - MeasureTheory.condExp m μ X) ^ 2)
Instances For
Conditional variance of a real-valued random variable. It is defined as 0
if any one of the
following conditions is true:
m
is not a sub-σ-algebra ofm₀
,μ
is not σ-finite with respect tom
,X - μ[X | m]
is not square-integrable.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Conditional variance of a real-valued random variable. It is defined as 0
if any one of the
following conditions is true:
m
is not a sub-σ-algebra ofm₀
,volume
is not σ-finite with respect tom
,X - 𝔼[X | m]
is not square-integrable.
Equations
- One or more equations did not get rendered due to their size.
Instances For
theorem
ProbabilityTheory.condVar_of_not_le
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{X : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
(hm : ¬m ≤ m₀)
:
theorem
ProbabilityTheory.condVar_of_not_sigmaFinite
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{hm : m ≤ m₀}
{X : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
(hμm : ¬MeasureTheory.SigmaFinite (μ.trim hm))
:
theorem
ProbabilityTheory.condVar_of_sigmaFinite
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{hm : m ≤ m₀}
{X : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
[MeasureTheory.SigmaFinite (μ.trim hm)]
:
condVar m X μ = if MeasureTheory.Integrable (fun (ω : Ω) => (X ω - MeasureTheory.condExp m μ X ω) ^ 2) μ then
if MeasureTheory.StronglyMeasurable fun (ω : Ω) => (X ω - MeasureTheory.condExp m μ X ω) ^ 2 then fun (ω : Ω) =>
(X ω - MeasureTheory.condExp m μ X ω) ^ 2
else MeasureTheory.AEStronglyMeasurable.mk
↑↑(MeasureTheory.condExpL1 hm μ fun (ω : Ω) => (X ω - MeasureTheory.condExp m μ X ω) ^ 2) ⋯
else 0
theorem
ProbabilityTheory.condVar_of_stronglyMeasurable
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{hm : m ≤ m₀}
{X : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
[MeasureTheory.SigmaFinite (μ.trim hm)]
(hX : MeasureTheory.StronglyMeasurable X)
(hXint : MeasureTheory.Integrable ((X - MeasureTheory.condExp m μ X) ^ 2) μ)
:
theorem
ProbabilityTheory.condVar_of_not_integrable
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{X : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
(hXint : ¬MeasureTheory.Integrable (fun (ω : Ω) => (X ω - MeasureTheory.condExp m μ X ω) ^ 2) μ)
:
@[simp]
theorem
ProbabilityTheory.condVar_zero
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{μ : MeasureTheory.Measure Ω}
:
@[simp]
theorem
ProbabilityTheory.condVar_const
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{μ : MeasureTheory.Measure Ω}
(hm : m ≤ m₀)
(c : ℝ)
:
theorem
ProbabilityTheory.stronglyMeasurable_condVar
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{X : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
:
theorem
ProbabilityTheory.condVar_congr_ae
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{X Y : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
(h : X =ᵐ[μ] Y)
:
theorem
ProbabilityTheory.condVar_of_aestronglyMeasurable
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{hm : m ≤ m₀}
{X : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
[hμm : MeasureTheory.SigmaFinite (μ.trim hm)]
(hX : MeasureTheory.AEStronglyMeasurable X μ)
(hXint : MeasureTheory.Integrable ((X - MeasureTheory.condExp m μ X) ^ 2) μ)
:
theorem
ProbabilityTheory.integrable_condVar
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{X : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
:
MeasureTheory.Integrable (condVar m X μ) μ
theorem
ProbabilityTheory.setIntegral_condVar
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{hm : m ≤ m₀}
{X : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
{s : Set Ω}
[MeasureTheory.SigmaFinite (μ.trim hm)]
(hX : MeasureTheory.Integrable ((X - MeasureTheory.condExp m μ X) ^ 2) μ)
(hs : MeasurableSet s)
:
The integral of the conditional variance Var[X | m]
over an m
-measurable set is equal to
the integral of (X - μ[X | m]) ^ 2
on that set.
theorem
ProbabilityTheory.condVar_ae_eq_condExp_sq_sub_sq_condExp
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{X : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
(hm : m ≤ m₀)
[MeasureTheory.IsFiniteMeasure μ]
(hX : MeasureTheory.Memℒp X 2 μ)
:
theorem
ProbabilityTheory.condVar_ae_le_condExp_sq
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{X : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
(hm : m ≤ m₀)
[MeasureTheory.IsFiniteMeasure μ]
(hX : MeasureTheory.Memℒp X 2 μ)
:
theorem
ProbabilityTheory.integral_condVar_add_variance_condExp
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{X : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
(hm : m ≤ m₀)
[MeasureTheory.IsProbabilityMeasure μ]
(hX : MeasureTheory.Memℒp X 2 μ)
:
Law of total variance
theorem
ProbabilityTheory.condVar_bot
{Ω : Type u_1}
{m₀ : MeasurableSpace Ω}
{X : Ω → ℝ}
{μ : MeasureTheory.Measure Ω}
[MeasureTheory.IsProbabilityMeasure μ]
(hX : AEMeasurable X μ)
:
theorem
ProbabilityTheory.condVar_smul
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{μ : MeasureTheory.Measure Ω}
(c : ℝ)
(X : Ω → ℝ)
:
@[simp]
theorem
ProbabilityTheory.condVar_neg
{Ω : Type u_1}
{m₀ m : MeasurableSpace Ω}
{μ : MeasureTheory.Measure Ω}
(X : Ω → ℝ)
: