Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
178 changes: 178 additions & 0 deletions lectures/_static/quant-econ.bib
Original file line number Diff line number Diff line change
Expand Up @@ -6207,6 +6207,37 @@ @article{Giannitsarou2005
pages = {276--287}
}

@article{EvansHonkapohjaWilliams2010,
author = {Evans, George W. and Honkapohja, Seppo and Williams, Noah},
title = {Generalized Stochastic Gradient Learning},
journal = {International Economic Review},
year = {2010},
volume = {51},
number = {1},
pages = {237--262},
doi = {10.1111/j.1468-2354.2009.00578.x}
}

@article{Amari1998,
author = {Amari, Shun-ichi},
title = {Natural Gradient Works Efficiently in Learning},
journal = {Neural Computation},
year = {1998},
volume = {10},
number = {2},
pages = {251--276}
}

@article{HeymannVandenEijnden2008,
author = {Heymann, Matthias and Vanden-Eijnden, Eric},
title = {The Geometric Minimum Action Method: A Least Action Principle on the Space of Curves},
journal = {Communications on Pure and Applied Mathematics},
year = {2008},
volume = {61},
number = {8},
pages = {1052--1117}
}

@article{MalmendierNagel2016,
author = {Malmendier, Ulrike and Nagel, Stefan},
title = {Learning from Inflation Experiences},
Expand Down Expand Up @@ -6824,6 +6855,153 @@ @article{Nielsen2013
doi = {10.1109/LSP.2013.2243726}
}

@misc{NielsenMLSS2015,
author = {Nielsen, Frank},
title = {Computational Information Geometry for Machine Learning},
howpublished = {Lecture slides, Machine Learning Summer School, Sydney},
year = {2015}
}

@article{Fisher1922,
author = {Fisher, Ronald A.},
title = {On the Mathematical Foundations of Theoretical Statistics},
journal = {Philosophical Transactions of the Royal Society of London. Series A},
year = {1922},
volume = {222},
pages = {309--368},
doi = {10.1098/rsta.1922.0009}
}

@article{Darmois1935,
author = {Darmois, Georges},
title = {Sur les lois de probabilit{\'e} {\`a} estimation exhaustive},
journal = {Comptes Rendus de l'Acad{\'e}mie des Sciences},
year = {1935},
volume = {200},
pages = {1265--1266}
}

@article{Koopman1936,
author = {Koopman, Bernard O.},
title = {On Distributions Admitting a Sufficient Statistic},
journal = {Transactions of the American Mathematical Society},
year = {1936},
volume = {39},
number = {3},
pages = {399--409},
doi = {10.1090/S0002-9947-1936-1501854-3}
}

@article{Pitman1936,
author = {Pitman, Edwin J. G.},
title = {Sufficient Statistics and Intrinsic Accuracy},
journal = {Mathematical Proceedings of the Cambridge Philosophical Society},
year = {1936},
volume = {32},
pages = {567--579}
}

@article{Rao1945,
author = {Rao, C. Radhakrishna},
title = {Information and the Accuracy Attainable in the Estimation of Statistical Parameters},
journal = {Bulletin of the Calcutta Mathematical Society},
year = {1945},
volume = {37},
pages = {81--91}
}

@article{CostaSantosStrapasson2015,
author = {Costa, Sueli I. R. and Santos, Sandra A. and Strapasson, Jo{\~a}o E.},
title = {Fisher Information Distance: A Geometrical Reading},
journal = {Discrete Applied Mathematics},
year = {2015},
volume = {197},
pages = {59--69}
}

@article{KhanZhang2022,
author = {Khan, Gabriel and Zhang, Jun},
title = {When Optimal Transport Meets Information Geometry},
journal = {Information Geometry},
year = {2022},
volume = {5},
pages = {47--78},
doi = {10.1007/s41884-022-00066-w}
}

@article{AmariKarakidaOizumi2018,
author = {Amari, Shun-ichi and Karakida, Ryo and Oizumi, Masafumi},
title = {Information Geometry Connecting {W}asserstein Distance and {K}ullback--{L}eibler Divergence via the Entropy-Relaxed Transportation Problem},
journal = {Information Geometry},
year = {2018},
volume = {1},
number = {1},
pages = {13--37}
}

@article{McCann1997,
author = {McCann, Robert J.},
title = {A Convexity Principle for Interacting Gases},
journal = {Advances in Mathematics},
year = {1997},
volume = {128},
number = {1},
pages = {153--179}
}

@article{Takatsu2011,
author = {Takatsu, Asuka},
title = {{W}asserstein Geometry of {G}aussian Measures},
journal = {Osaka Journal of Mathematics},
year = {2011},
volume = {48},
number = {4},
pages = {1005--1026}
}

@article{PeyreCuturi2019,
author = {Peyr{\'e}, Gabriel and Cuturi, Marco},
title = {Computational Optimal Transport: With Applications to Data Science},
journal = {Foundations and Trends in Machine Learning},
year = {2019},
volume = {11},
number = {5--6},
pages = {355--607}
}

@article{Gelbrich1990,
author = {Gelbrich, Matthias},
title = {On a Formula for the {$L^2$} {W}asserstein Metric between Measures on {E}uclidean and {H}ilbert Spaces},
journal = {Mathematische Nachrichten},
year = {1990},
volume = {147},
number = {1},
pages = {185--203},
doi = {10.1002/mana.19901470121}
}

@article{MatejkaMcKay2015,
author = {Mat{\v{e}}jka, Filip and McKay, Alisdair},
title = {Rational Inattention to Discrete Choices: A New Foundation for the Multinomial Logit Model},
journal = {American Economic Review},
year = {2015},
volume = {105},
number = {1},
pages = {272--298},
doi = {10.1257/aer.20130047}
}

@article{DupuyGalichon2014,
author = {Dupuy, Arnaud and Galichon, Alfred},
title = {Personality Traits and the Marriage Market},
journal = {Journal of Political Economy},
year = {2014},
volume = {122},
number = {6},
pages = {1271--1319},
doi = {10.1086/677191}
}

@article{AndersonDePalmaThisse1988,
author = {Anderson, Simon P. and de Palma, Andr{\'e} and Thisse, Jacques-Fran{\c{c}}ois},
title = {A Representative Consumer Theory of the Logit Model},
Expand Down
13 changes: 8 additions & 5 deletions lectures/_toc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,6 @@ parts:
numbered: true
chapters:
- file: divergence_measures
- file: exponential_families
- file: information_projections
- file: approximation_errors
- file: specification_tests
- file: turbulence_inference
- file: likelihood_ratio_process
- file: likelihood_ratio_process_2
- file: likelihood_var
Expand All @@ -57,6 +52,14 @@ parts:
- file: pricing_information
- file: market_diffusion
- file: gallant_tauchen
- caption: Information Geometry
numbered: true
chapters:
- file: exponential_families
- file: information_projections
- file: approximation_errors
- file: specification_tests
- file: turbulence_inference
- caption: Linear Programming
numbered: true
chapters:
Expand Down
50 changes: 47 additions & 3 deletions lectures/approximation_errors.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ kernelspec:

## Overview

When an econometrician estimates a model that does not contain the process that generated the data, the maximum likelihood estimator converges, under regularity conditions, to the member of the model that is closest to the true process in the sense of Kullback–Leibler (KL) divergence.
When an econometrician estimates a family of models that does not contain the process that generated the data, the maximum likelihood estimator converges, under regularity conditions, to the model in the family that is closest to the true process in the sense of Kullback–Leibler (KL) divergence.

In {doc}`information_projections` we called that member the **m-projection** of the true distribution onto the model.
In {doc}`information_projections` we called that model the **m-projection** of the true distribution onto the family.

We organize this lecture around one consequence of that fact: by choosing the model, the data, and any filter that transforms the data, an econometrician chooses which projection an estimator computes.

Expand Down Expand Up @@ -62,7 +62,7 @@ We use the following imports.
import numpy as np
import matplotlib.pyplot as plt
from scipy import integrate
from scipy.linalg import toeplitz, cho_factor, cho_solve
from scipy.linalg import toeplitz, cho_factor, cho_solve, sqrtm
from scipy.optimize import minimize
```

Expand Down Expand Up @@ -1046,6 +1046,50 @@ Sims's filter $1 - \kappa(L)\kappa(L^{-1})$ is zero at $\pm\pi/2$, at $\pi$, and

It removes the deterministic seasonal, whose spectral measure puts all its mass at $\pm\pi/2$, and the equality applies to what remains, as {ref}`ae_ex_invariance` shows.

The invariance belongs to the KL divergence, which compares two processes frequency by frequency through the ratio $f / g$.

A distance that measures how far probability mass must move does not have it.

The squared 2-Wasserstein distance of {doc}`exponential_families` between $N(0, \Sigma_1)$ and $N(0, \Sigma_2)$ is $\operatorname{tr}\left(\Sigma_1 + \Sigma_2 - 2 (\Sigma_1^{1/2} \Sigma_2 \Sigma_1^{1/2})^{1/2}\right)$ {cite}`Gelbrich1990`.

The covariance matrices of $T$ consecutive observations of two stationary processes are nearly diagonalized by the same Fourier basis when $T$ is large, so for two Gaussian processes with mean zero this distance, divided by $T$, converges to

$$
\frac{1}{2\pi} \int_{-\pi}^{\pi} \left( \sqrt{f(\omega)} - \sqrt{g(\omega)} \right)^2 d\omega .
$$ (ae_w2_rate)

Filtering both processes by $c(L)$ multiplies the integrand by $\lvert c(e^{-i\omega}) \rvert^2$, so the filter changes the distance even when it leaves the divergence rate unchanged.

We check {eq}`ae_w2_rate` for a first-order autoregression with $\rho = 0.8$ and white noise with variance $2$, and filter both by $1 - 0.9 L$.

```{code-cell} ipython3
def w2_squared_gaussian(S1, S2):
"""Squared 2-Wasserstein distance between N(0, S1) and N(0, S2)."""
root = sqrtm(S1)
return np.trace(S1 + S2 - 2 * np.real(sqrtm(root @ S2 @ root)))


def w2_rate(f, g):
"""(1/2π) ∫ (√f - √g)² dω on the grid."""
return np.mean((np.sqrt(f) - np.sqrt(g))**2)


f_ar, g_wn = ar_spectrum(0.8), ar_spectrum(0.0, 2.0)
for T_w in (100, 400):
S_f, S_g = toeplitz(autocov(f_ar, T_w - 1)), toeplitz(autocov(g_wn, T_w - 1))
print(f"T = {T_w}: W2² / T = {w2_squared_gaussian(S_f, S_g) / T_w:.4f}")

gain_sq = np.abs(1 - 0.9 * z)**2
print(f"formula (ae_w2_rate): {w2_rate(f_ar, g_wn):.4f}")
print(f"filtered by 1 - 0.9L: W2 rate {w2_rate(gain_sq * f_ar, gain_sq * g_wn):.4f}, "
f"KL rate {kl_rate(f_ar, g_wn):.4f} before and "
f"{kl_rate(gain_sq * f_ar, gain_sq * g_wn):.4f} after")
```

The filter leaves the KL divergence rate at its value and changes the Wasserstein rate.

{doc}`exponential_families` describes the same contrast for transformations of a single random variable.

A filter cannot delete a band of frequencies from the likelihood.

A filter whose frequency response is zero on a band makes the filtered processes linearly deterministic, and formula {eq}`ae_kl_rate`, which assumes spectral densities bounded away from zero, no longer applies.
Expand Down
Loading
Loading