Quant Memo
Core

Method of Moments and GMM

Estimation by matching sample moments to their theoretical counterparts, the classical method of moments, its generalization to more moment conditions than parameters (GMM), and why GMM underlies asset-pricing tests.

Prerequisites: Bias, Variance, and the Quality of Estimators, Expectation, Variance & Moments

The method of moments is the oldest estimation idea in statistics and, in its modern generalized form, one of the most important in finance. The logic is disarmingly simple: a model tells you what the population moments of the data should be as functions of the parameters; a sample gives you sample moments; set them equal and solve. Where maximum likelihood needs a full distributional assumption, the method of moments needs only that a few expectations hold, which is exactly why asset pricing, where theory pins down expectations but not full distributions, is built on it.

Classical method of moments

Suppose the model has kk parameters θ=(θ1,,θk)\theta = (\theta_1, \dots, \theta_k) and the population moments are known functions μj(θ)=E[Xj]\mu_j(\theta) = \mathbb{E}[X^j]. Replace each with its sample analogue μ^j=1niXij\hat\mu_j = \frac1n\sum_i X_i^j and solve the kk equations

μj(θ^)=1ni=1nXij,j=1,,k.\mu_j(\hat\theta) = \frac{1}{n}\sum_{i=1}^n X_i^{\,j}, \qquad j = 1, \dots, k.

The justification is the The Law of Large Numbers: sample moments converge to population moments, so the solution θ^\hat\theta converges to the truth, the estimator is consistent. It is generally not efficient (it ignores information MLE would use), but it is often available in closed form when MLE requires numerical optimization, and it makes an excellent starting value for a likelihood optimizer.

Worked example: fitting a gamma to loss data

The gamma distribution with shape α\alpha and rate β\beta has mean α/β\alpha/\beta and variance α/β2\alpha/\beta^2. Match the first two moments to the sample mean xˉ\bar x and sample variance s2s^2:

α^β^=xˉ,α^β^2=s2.\frac{\hat\alpha}{\hat\beta} = \bar x, \qquad \frac{\hat\alpha}{\hat\beta^2} = s^2.

Dividing the second by the first gives 1/β^=s2/xˉ1/\hat\beta = s^2/\bar x, so β^=xˉ/s2\hat\beta = \bar x / s^2 and α^=xˉβ^=xˉ2/s2\hat\alpha = \bar x \hat\beta = \bar x^2/s^2. Two moments, two parameters, a closed-form fit, no optimizer, no distributional score to differentiate. This is the everyday appeal of the method: fast, transparent, and robust to not knowing (or not trusting) the full likelihood.

Generalized method of moments (GMM)

The powerful generalization drops the requirement that the number of moment conditions equal the number of parameters. Economic theory typically delivers moment conditions of the form

E[g(Xi,θ0)]=0,\mathbb{E}[\,g(X_i, \theta_0)\,] = 0,

where gg is a vector of mm functions and θ\theta has dimension kmk \le m. The sample analogue gˉ(θ)=1nig(Xi,θ)\bar g(\theta) = \frac1n\sum_i g(X_i,\theta) cannot in general be driven to exactly zero when m>km > k (more equations than unknowns, the model is overidentified). GMM instead minimizes a quadratic form:

θ^GMM=argminθ gˉ(θ)Wgˉ(θ),\hat\theta_{\text{GMM}} = \arg\min_\theta \ \bar g(\theta)^\top\, W\, \bar g(\theta),

for a positive-definite weighting matrix WW. Hansen's theorem says the estimator is consistent and asymptotically normal for any such WW, and the efficient choice is W=S1W = S^{-1}, the inverse of the long-run covariance of the moment conditions S=Var(ngˉ)S = \operatorname{Var}(\sqrt{n}\,\bar g). With the optimal weight, overidentification becomes a virtue: the extra moment conditions both sharpen the estimate and provide a specification test.

The J-test and the connections

When the model is overidentified, the minimized objective is not zero, and its scaled value is the Hansen J-statistic, which is χmk2\chi^2_{m-k} under a correct model, a test of whether the mm moment conditions are jointly consistent with only kk parameters. GMM also unifies estimators you already know:

  • OLS is GMM with the moment condition E[xiεi]=0\mathbb{E}[x_i \varepsilon_i] = 0 (regressors orthogonal to errors). See Ordinary Least Squares (OLS).
  • Instrumental variables / 2SLS is GMM with E[ziεi]=0\mathbb{E}[z_i \varepsilon_i] = 0 for instruments zz. Overidentification (more instruments than regressors) is exactly the GMM-with-m>km>k case. See Endogeneity and Instrumental Variables.
  • Maximum likelihood is GMM with the score as the moment condition, E[s(θ)]=0\mathbb{E}[s(\theta)] = 0.

This is why GMM is the lingua franca of empirical asset pricing: a pricing model such as E[mt+1Rt+1]=1\mathbb{E}[m_{t+1} R_{t+1}] = 1 (a stochastic discount factor mm pricing every return RR) is a set of moment conditions, one per asset, estimated and tested directly by GMM with no distributional assumption on returns.

Failure modes in financial data

  • Weak identification. If the moment conditions are nearly flat in θ\theta, the analogue of weak instruments, GMM estimates are badly biased and the asymptotic normal approximation fails, even in large samples. Asset-pricing tests with many test assets and few real factors are prone to this.
  • Estimating the weighting matrix. The efficient W=S1W = S^{-1} must itself be estimated, and SS is a long-run covariance that requires HAC (Newey–West) correction for autocorrelated moments; a poorly estimated SS in finite samples can make "efficient" two-step GMM less reliable than one-step. Continuously-updated or iterated GMM is often used to reduce this.
  • Too many moments. Adding moment conditions raises asymptotic efficiency but worsens finite-sample bias, a classic bias–variance tension (see Bias, Variance, and the Quality of Estimators). With hundreds of test assets and a short return history, the estimated SS is near-singular and the J-test over-rejects.
  • Fat tails and outliers. Higher moments are dominated by extremes; a method-of-moments fit that matches the sample kurtosis of returns is hostage to a handful of crash days.

In interviews

The classic ask is to fit a two-parameter distribution by matching two moments, the gamma or the uniform on [0,θ][0,\theta] are common; be able to set up μj(θ^)=μ^j\mu_j(\hat\theta) = \hat\mu_j and solve in closed form. Know the one-sentence contrast with MLE: method of moments needs only that certain expectations hold (robust, consistent, usually not efficient), while MLE needs the full density (efficient, but fragile to misspecification). For quant-research roles, be ready to say what GMM adds, estimation with more moment conditions than parameters, the efficient weighting W=S1W = S^{-1}, and the J-test, and to note that OLS, IV, and MLE are all special cases, which is the unifying insight interviewers are listening for.

Related concepts

Practice in interviews

Further reading

  • Hayashi, Econometrics (Ch. 3, GMM)
  • Hansen (1982), Large Sample Properties of GMM Estimators
  • Cochrane, Asset Pricing (Ch. 10–11)
ShareTwitterLinkedIn