Why a GMM workshop needs more than an estimate
A dynamic-panel estimate is not a single coefficient detached from its construction. Its credibility depends on the model, the timing assumptions that make particular lags valid instruments, the number of moment conditions, and the diagnostics and sensitivity checks reported alongside the estimate. A plausible-looking coefficient can still be unpersuasive if those pieces do not fit together.
This hypothetical application walks through a difference-GMM analysis of persistent productivity. It focuses on a transparent, restricted instrument set and on what a complete report should say. The estimates and test results below are illustrative, not evidence about an actual industry or data set.
Model, timing assumptions, and moments
Suppose a balanced panel follows \(N=120\) firms over \(T=10\) periods. Let \(y_{it}\) be firm \(i\)'s log productivity in period \(t\), and let \(x_{it}\) be its investment rate, measured in percentage points. Consider the dynamic model
Here \(\eta_i\) is a time-invariant firm effect, \(\lambda_t\) is a common period effect, and \(\varepsilon_{it}\) is the idiosyncratic error. The parameter \(\rho\) describes conditional persistence, while \(\beta\) is the conditional association between investment and log productivity in this model. Neither coefficient alone establishes a causal effect.
First differencing removes \(\eta_i\), but creates an equation in which the lagged outcome is endogenous: \(\Delta y_{i,t-1}\) contains \(\varepsilon_{i,t-1}\), which also appears in \(\Delta\varepsilon_{it}=\varepsilon_{it}-\varepsilon_{i,t-1}\). The analysis therefore needs instruments supported by explicit timing assumptions.
These are substantive assumptions, not consequences of GMM estimation. In particular, serial correlation in the level errors can invalidate the proposed lagged-outcome instruments. The predetermined status of \(x_{it}\) is also an assumption about its relationship with the errors, not merely a label assigned by the analyst.
Constructing a controlled instrument set
With ten periods, differenced observations are available for \(t=3,\ldots,10\), giving eight differenced equations per firm. For this illustration, use lagged levels \(y_{i,t-2}\) through \(y_{i,t-7}\) for the lagged dependent variable, and \(x_{i,t-1}\) through \(x_{i,t-6}\) for \(\Delta x_{it}\). The lag depths follow the moment conditions above. The instrument matrix is collapsed: instruments at the same lag depth share a column across time rather than generating a separate column for every equation and lag combination. Include the eight differenced period-effect indicators as standard instruments for the period terms.
The resulting instrument matrix has 20 columns: six lag-depth columns for \(y\), six for \(x\), and eight period indicators. The differenced regression has ten estimated coefficients: \(\rho\), \(\beta\), and eight period-effect coefficients. Thus the specification has ten overidentifying restrictions, provided the instrument matrix has full relevant rank. The instrument count is reported explicitly because the number of moments affects both estimation and the interpretation of specification tests.
Worked Example: Checking the instrument count and overidentification degrees of freedom
For the stated specification, count the instruments and parameters before interpreting the Hansen test.
There are \(6\) collapsed lag columns for \(y\), \(6\) for \(x\), and \(8\) period indicators, so the total number of instrument columns is
The estimated coefficient vector contains \(\rho\), \(\beta\), and eight period-effect coefficients, so \(k=10\). Under the usual rank condition, the overidentification test has
This arithmetic does not show that the instruments are valid. It establishes the degrees of freedom used for the test and makes the instrument count auditable.
Two-step GMM estimation
Stack the differenced equations within each firm. Let \(\Delta Y_i\) be the stacked outcome vector, \(\Delta X_i\) the matrix of differenced regressors (including the period terms), and \(Z_i\) the instrument matrix. The residual vector at coefficient value \(\theta\) is \(\Delta u_i(\theta)=\Delta Y_i-\Delta X_i\theta\). The sample moment vector is
GMM chooses the coefficient vector making the sample moments small under a positive definite weighting matrix \(W\): it minimizes \(g_N(\theta)'Wg_N(\theta)\). A one-step estimate uses an initial weighting matrix; the two-step estimate updates the weighting matrix using residuals from the initial estimate. In a common firm-clustered construction, the estimated covariance of the moments is based on \(\frac{1}{N}\sum_i Z_i'\Delta u_i\Delta u_i'Z_i\), and the second-step weight is its inverse when that inverse exists. The reported standard errors should account for the two-step estimation procedure and the chosen finite-sample correction.
Worked Example: Interpreting the two-step coefficient estimates
Suppose the hypothetical two-step output gives \(\hat{\rho}=0.612\) with standard error \(0.084\), and \(\hat{\beta}=0.238\) with standard error \(0.071\). These standard errors are assumed to use an appropriate two-step finite-sample correction.
The investment estimate is \(0.238\) log-productivity units per percentage point of investment rate, conditional on the lagged outcome and period effects. A one-percentage-point increase in the investment rate is associated with a \(0.238\)-unit increase in log productivity in the specified differenced model; this is not by itself a causal conclusion.
For a large-sample normal reference, the coefficient-to-standard-error ratio for investment is
A two-sided normal 95% confidence interval is approximately
Under the stated model and inference procedure, the interval ranges from about \(0.0988\) to \(0.3772\) log-productivity units per percentage point. Its frequentist 95% coverage describes the long-run performance of the interval procedure under repeated sampling; it is not a 95% probability statement about this fixed coefficient.
For persistence, \(0.612/0.084=7.286\), also far from zero on the same normal reference. The estimate describes persistence conditional on the included regressors and effects; it does not imply that a shock necessarily has a causal or permanent effect.
Serial-correlation and overidentification diagnostics
The Arellano–Bond tests examine serial correlation in differenced residuals. Under the null of no serial correlation of a given order in the differenced residuals, the test statistic is compared with a standard normal reference in large samples. First-order correlation in differenced residuals is generally expected when the level errors are serially uncorrelated, because differencing makes adjacent errors share a level error with opposite signs. The second-order test is the key diagnostic here: evidence of second-order correlation can undermine the lagged-level moments used for the differenced equation.
Worked Example: Reading the Arellano–Bond tests
Suppose the first-order test reports \(z=-4.31\), with \(p<0.001\), and the second-order test reports \(z=0.72\). For the second-order test, the two-sided standard-normal p-value is
The first-order result is consistent with the correlation induced by differencing and is not, on its own, evidence against the assumed lack of serial correlation in level errors. At the 5% significance level, the second-order test does not reject its null. This is a failure to find evidence of second-order correlation, not proof that all instrument moments are valid.
The Hansen test evaluates the joint compatibility of the overidentifying moment restrictions with the data under the maintained estimation assumptions. Its null is that the overidentifying restrictions are valid. The test statistic is compared with a chi-square reference distribution whose degrees of freedom are the number of independent overidentifying restrictions. A small p-value is evidence against the joint restrictions; a large p-value is not confirmation that every instrument is valid.
Worked Example: Interpreting the Hansen test
For the 20-instrument, 10-parameter specification, suppose the robust Hansen statistic is \(J=12.6\). The degrees of freedom are \(10\), as counted above. The upper-tail probability is
At the 5% level, this test does not reject the joint overidentifying restrictions. The precise conclusion is limited: the test does not identify a conflict between the moments and the data at this level. It does not establish that the timing assumptions are true, nor does it rule out weak instruments or problematic instrument proliferation.
Sensitivity analysis and a complete report
A single lag range can make the result depend heavily on a particular instrument design. Sensitivity analysis therefore changes defensible instrument choices and compares the coefficient estimates, diagnostics, and number of instruments. The purpose is not to search until a preferred p-value appears. It is to assess whether the substantive conclusion is stable under reasonable restrictions motivated by the timing assumptions and sample size.
| Illustrative specification | Instruments | \(\hat{\rho}\) | \(\hat{\beta}\) | AR(2) result | Hansen result |
|---|---|---|---|---|---|
| Restricted baseline: \(y\) lags 2–7; \(x\) lags 1–6 | 20 | 0.612 | 0.238 | \(z=0.72,\ p=0.472\) | \(J=12.6,\ df=10,\ p=0.2469\) |
| Narrower range: \(y\) lags 2–4; \(x\) lags 1–3 | 14 | 0.574 | 0.211 | \(z=0.61,\ p=0.542\) | \(J=3.7,\ df=4,\ p\approx0.448\) |
The narrower specification has six lag-depth columns plus eight period indicators, giving 14 instruments; with ten coefficients, it has four overidentifying restrictions. Its illustrative Hansen p-value is \(P(\chi^2_4\geq3.7)\approx0.448\). The investment estimate changes from \(0.238\) to \(0.211\) log-productivity units per percentage point, and the persistence estimate changes from \(0.612\) to \(0.574\). These estimates are directionally similar, but the difference should be reported rather than concealed. Neither specification’s non-rejection by the Hansen test proves instrument validity.
A concise report should identify the panel dimensions and sample, model and estimator, timing assumptions, instrument types and lag ranges, whether the matrix was collapsed, total instrument and parameter counts, coefficient estimates with standard errors and units, and the serial-correlation and overidentification tests. It should then state how the estimates respond to reasonable instrument restrictions. This makes the evidence assessable rather than presenting one preferred coefficient as if its design were inevitable.
Common pitfall: treating non-rejection as validation
A common mistake is to say, “The Hansen p-value is above 0.05, so the instruments are valid.” That conclusion is too strong. A non-rejection means the test did not find sufficient evidence against the joint restrictions at the chosen level. It does not verify the timing assumptions, and a large instrument set can reduce the test’s ability to reveal invalid moments. The correction is to describe the result as non-rejection, report the instrument count, assess serial-correlation diagnostics, and show sensitivity to a defensible, more restricted instrument set.
A related reporting error is to omit the instrument count or interpret an acceptable AR(2) result as proof of exogeneity. AR(2) addresses a particular residual-correlation implication of the difference moments; it does not test every source of endogeneity. Each diagnostic answers a limited question, so conclusions should reflect that scope.
Check Your Understanding
Use the assumptions and hypothetical results in this workshop to answer the following questions.
- Why is \(\Delta y_{i,t-1}\) endogenous in the differenced equation, and what role do lagged levels play?
- For the baseline specification, verify the instrument count and the Hansen-test degrees of freedom.
- Explain why first-order serial correlation in differenced residuals may be expected even when the level errors are serially uncorrelated.
- State the appropriate conclusion from the reported AR(2) and Hansen tests without claiming that the instruments have been proven valid.
- What does the estimated investment coefficient mean in its stated units, and why does it not by itself establish causation?
- What information from the narrower-lag sensitivity analysis should be included in the final report?