RATS 11
RATS 11

The J-specification test is due originally to Hansen(1982)—it is a test of overidentifying restrictions in a Generalized Method of Moments estimator. By limiting ourselves to a notation appropriate for those models which can be estimated using single-equation methods, we can demonstrate more easily how these tests work. Assume

 

(1) \(y_t  = f\left( {X_t ,\beta } \right) + u_t \)

(2) \(E\left( {Z'_t {\kern 1pt} {\kern 1pt} u_t } \right) = 0\)

 

with some required regularity conditions on differentiability and moments of the processes. \(f\) will just be \(X_t \beta \) for a linear regression. The \(Z\) are the instruments. If \(Z\) is the same dimension as \(\beta\), the model is just identified, and we can test nothing. Hansen’s key testing result is that

 

(3) \({\bf{u'}}{\kern 1pt} {\kern 1pt} {\kern 1pt} {\bf{Z}}{\kern 1pt} {\bf{W}}{\kern 1pt} {\bf{Z'}}{\kern 1pt} {\kern 1pt} {\bf{u}}\sim\chi ^2 \)

 

when the weighting matrix \(\mathbf{W}\) is chosen “optimally.” The degrees of freedom is the difference between the number of orthogonality conditions in (2) and the number of parameters in the \(\beta\) vector.

 

This test is automatically included in the output from LINREG, AR1, NLLS, NLSYSTEM and SUR as the J-Specification. This generates output as shown below, with the first line showing the degrees of freedom (the difference between the number of conditions in (2) and the number of estimated coefficients) and the test statistic, and the second line showing the marginal significance level:

 

J-Specification(4)                7.100744

Significance Level of J           0.13065919

 

These results would indicate that the null hypothesis (that the overidentifying restrictions are valid) can be accepted.

 

Variables Defined
 

The following statistics related to this calculation are produced by the estimation instructions:

 

%JSTAT

test statistics for overidentification (for instrumental variables regressions) (REAL)

%JSIGNIF

significance level of %JSTAT (REAL)

%NDFJ

degrees of freedom for %JSTAT (INTEGER)

%UZWZU

\({\bf{u'}}{\kern 1pt} {\bf{Z}}{\kern 1pt} {\bf{W}}{\kern 1pt} {\bf{Z'u}}\)  (REAL)

%WMATRIX

final weight matrix for GMM (SYMMETRIC)

 

Robust Versions

 

If the weighting matrix used in estimation isn’t the optimal choice, there are two ways to “robustify” the test. The first is described in Hansen(1982)—it computes an adjusted covariance matrix \(\mathbf{A}\) for \({\bf{Z'}}{\kern 1pt} {\kern 1pt} {\bf{u}}\) so that \({\bf{u'}}{\kern 1pt} {\kern 1pt} {\kern 1pt} {\bf{Z}}{\kern 1pt} {\bf{A}}^{ - 1} {\kern 1pt} {\bf{Z'}}{\kern 1pt} {\kern 1pt} {\bf{u}}\sim\chi ^2 \). This is chosen by adding the JROBUST=STATISTIC option.


 

The other is described in Jagannathan and Wang(1996). It uses the standard \({\bf{u'}}{\kern 1pt} {\bf{Z}}{\kern 1pt} {\bf{W}}{\kern 1pt} {\bf{Z'u}}\) as the test statistic, but they show that it has an asymptotic distribution which is that of a more general quadratic form in independent Normals. You choose this with the option JROBUST=DISTRIBUTION.


 


Copyright © 2025 Thomas A. Doan