Title

weakivtest2 —— A Robust Test for Weak Instruments with Multiple Endogenous Regressors

Syntax

weakivtest2 [, level(#) tau(#) points(#)]

level(#) confidence level; the default is level(95);

tau(#) Nagar's relative bias threshold; the default is tau(0.1);

points(#) number of starting points for the optimization step; the default is points(1000);

fast only obtain the simplified and conversative critical value to save time.

Description

weakivtest2 implements the weak instrument test with multiple endogenous regressors in Two-Stage Least Squares (Lewis and Mertens, 2022).
It is a postestimation command for ivreg2 and xtivreg2 (fixed effect only).
weakivtest2 tests the null hypothesis of weak instruments.
The test rejects the null hypothesis when the test statistic exceeds a critical value, which depends on the estimator, the significance level, and the desired weak instrument threshold tau.
weakivtest2 extends the Stock and Yogo's (2005) test by allowing heteroskedasticity and autocorrelation, and extends Montiel Olea and Pflueger's (2013) test by allowing multiple endogenous regressors.

weakivtest2 estimates the variance-covariance matrix of errors as specified in the preceding ivreg2 or xtivreg2 command.
The following options are supported:
robust estimates an Eicker-Huber-White heteroskedasticity robust variance-covariance matrix;
cluster(varlist) estimates a variance-covariance matrix clustered by the specified variable;
robust bw(#) estimates a heteroskedasticity and autocorrelation-consistent variance-covariance matrix computed with a Bartlett (Newey-West) kernel with # bandwidth.
bw(#) without the robust option requests estimates that are autocorrelation-consistent but not heteroskedasticity-consistent.

Note: You must install avar by typing "ssc install avar" before running weakivtest2.

Stored results

weakivtest2 stores the following in r():

Scalars

r(tau) Nagar's (1959) relative bias threshold

r(alpha) confidence level alpha

r(wiv_stat) Lewis and Mertens's (2022) weak-IV test statistic

r(wiv_stat_sy) Stock and Yogo's (2005) weak-IV test statistic

r(wiv_cv) critical value for Lewis and Mertens's (2022) statistc with Imhof's (1961) approximation

r(wiv_cv_simplified) critical value for Lewis and Mertens's (2022) statistc, simplified version

r(wiv_cv_sy) critical value for Stock and Yogo's (2005) statistic with Nagar's (1959) approximation

References

Imhof, J. P., 1961. "Computing the distribution of quadratic forms in normal variables." Biometrika, 48(3/4), 419-426.

Lewis, Daniel J., and Karel Mertens, 2022. "A robust test for weak instruments with multiple endogenous regressors.". Working Paper.

Montiel Olea, J. L. and C. E. Pflueger, 2013. "A robust test for weak instruments." Journal of Business and Economic Statistics, 31, 358-369.

Nagar, A. L., 1959. "The bias and moment matrix of the general k-class estimators of the parameters in simultaneous equations." Econometrica: Journal of the Econometric Society, 575-595.

Stock, J. and M. Yogo, 2005. "Testing for weak instruments in linear IV regression." In Identification and Inference for Econometric Models: Essays in Honor of Thomas Rothenberg, Chapter 5 80-108.

Author

Lingyun ZHOU

PBC School of Finance, Tsinghua University.