Ricardo,
I saw this error message too. Then, I changed the version "version
10.0" and it runs.
After, using version 10.1, it runs too, but I don�t know why:
. version
version 10.1
. use http://www.stata-press.com/data/r7/abdata.dta
. xtabond2 n l(1/2).n l(0/1).w l(0/2).(k ys), gmm(w k, lag(1 .))
gmm(ys, lag(2 .)) iv(rec) robust
> twostep
Favoring space over speed. To switch, type or click on mata: mata set
matafavor speed, perm.
Warning: Two-step estimated covariance matrix of moments is singular.
Using a generalized inverse to calculate optimal weighting matrix
for two-step estimation.
Difference-in-Sargan statistics may be negative.
Dynamic panel-data estimation, two-step system GMM
------------------------------------------------------------------------------
Group variable: id Number of obs = 751
Time variable : year Number of groups = 140
Number of instruments = 116 Obs per group: min = 5
Wald chi2(10) = 15287.00 avg = 5.36
Prob > chi2 = 0.000 max = 7
------------------------------------------------------------------------------
| Corrected
n | Coef. Std. Err. z P>|z| [95% Conf. Interval]
-------------+----------------------------------------------------------------
n |
L1. | .865203 .066758 12.96 0.000 .7343599 .9960462
L2. | .0684323 .0661299 1.03 0.301 -.06118 .1980446
w |
--. | -.4106478 .1988743 -2.06 0.039 -.8004343 -.0208612
L1. | .4472386 .1550677 2.88 0.004 .1433114 .7511658
k |
--. | .3481076 .0468468 7.43 0.000 .2562896 .4399256
L1. | -.1372164 .0623217 -2.20 0.028 -.2593647 -.0150681
L2. | -.1548901 .0404359 -3.83 0.000 -.2341429 -.0756373
ys |
--. | .4902727 .1301203 3.77 0.000 .2352417 .7453037
L1. | -.4540193 .2325855 -1.95 0.051 -.9098785 .00184
L2. | .0742544 .1417563 0.52 0.600 -.2035828 .3520916
_cons | -.5482326 .4491777 -1.22 0.222 -1.428605 .3321395
------------------------------------------------------------------------------
Instruments for first differences equation
Standard
D.(rec)
GMM-type (missing=0, separate instruments for each period unless collapsed)
L(1/.).(w k)
L(2/.).ys
Instruments for levels equation
Standard
_cons
rec
GMM-type (missing=0, separate instruments for each period unless collapsed)
D.(w k)
DL.ys
------------------------------------------------------------------------------
Arellano-Bond test for AR(1) in first differences: z = -2.97 Pr > z = 0.003
Arellano-Bond test for AR(2) in first differences: z = -1.76 Pr > z = 0.078
------------------------------------------------------------------------------
Sargan test of overid. restrictions: chi2(105) = 274.85 Prob > chi2 = 0.000
(Not robust, but not weakened by many instruments.)
Hansen test of overid. restrictions: chi2(105) = 107.69 Prob > chi2 = 0.409
(Robust, but can be weakened by many instruments.)
Difference-in-Hansen tests of exogeneity of instrument subsets:
GMM instruments for levels
Hansen test excluding group: chi2(84) = 83.08 Prob > chi2 = 0.508
Difference (null H = exogenous): chi2(21) = 24.61 Prob > chi2 = 0.265
gmm(w k, lag(1 .))
Hansen test excluding group: chi2(25) = 36.14 Prob > chi2 = 0.069
Difference (null H = exogenous): chi2(80) = 71.54 Prob > chi2 = 0.739
gmm(ys, lag(2 .))
Hansen test excluding group: chi2(71) = 75.53 Prob > chi2 = 0.334
Difference (null H = exogenous): chi2(34) = 32.16 Prob > chi2 = 0.558
iv(rec)
Hansen test excluding group: chi2(104) = 106.97 Prob > chi2 = 0.401
Difference (null H = exogenous): chi2(1) = 0.72 Prob > chi2 = 0.396
Best,
Joao Lima
2008/8/13 ricardo sierra <[email protected]>:
> Dear all,
>
> After reading Nick's message about the new version of Stata I
> immediately made the update. Then, trying to run an old dofile that
> used the user-written command of xtabond2 I get the following error:
>
>
> . xtabond2 FISpc L.FISpc traspc alcalde elecc_alcalde year_elecc,
> gmm(L.FISpc L.tras, collapse laglimits(. 1)) iv(alcalde elecc_alcalde
> year_elecc) two robust
>
> (max() in lmatabase, compiled by Stata 10.1, is too new to be run by
> this version of Stata and so was ignored)
>
> xtabond2_mata(): 3499 max() not found<istmt>: - function returned error
>
> The information provided in -h whatsnew - says nothing about possible
> changes to xtabond2.
>
> (I'm running Stata/SE 10.0 in a Windows XP system)
>
> Any suggestions??
>
> Best,
>
> R
> *
> * For searches and help try:
> * http://www.stata.com/help.cgi?search
> * http://www.stata.com/support/statalist/faq
> * http://www.ats.ucla.edu/stat/stata/
>
--
-------------------------------
Joao Ricardo Lima
Professor
UFPB-CCA-DCFS
+553138923914
-------------------------------
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/statalist/faq
* http://www.ats.ucla.edu/stat/stata/