I need to compare parameters of equation coming from SUR and GLM estimations. So I need to code a procedure for Hausman Specification Test. Because I am unable to subset parameters of first equation from a SUR estimation. I filtered parameter vector and var-cov matrix of SUR estimation
Code:
sysuse sp500.dta tsset date sureg (open L1.open L2.open L1.high L2.high L3.high) (high L1.open L2.open L1.high L2.high) Seemingly unrelated regression ------------------------------------------------------------------------------ Equation Obs Params RMSE "R-squared" chi2 P>chi2 ------------------------------------------------------------------------------ open 90 5 7.61825 0.9928 12416.11 0.0000 high 90 4 11.59675 0.9828 5156.78 0.0000 ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ | Coefficient Std. err. z P>|z| [95% conf. interval] -------------+---------------------------------------------------------------- open | open | L1. | -.4114277 .1297403 -3.17 0.002 -.6657139 -.1571415 L2. | .0716423 .091755 0.78 0.435 -.1081943 .2514789 | high | L1. | 1.339624 .0796114 16.83 0.000 1.183588 1.495659 L2. | .094866 .1446546 0.66 0.512 -.1886517 .3783837 L3. | -.0810755 .0515966 -1.57 0.116 -.182203 .0200519 | _cons | -29.7035 11.58405 -2.56 0.010 -52.40783 -6.999178 -------------+---------------------------------------------------------------- high | open | L1. | -.614001 .1973872 -3.11 0.002 -1.000873 -.2271291 L2. | .0386898 .1194357 0.32 0.746 -.1954 .2727795 | high | L1. | 1.374734 .1211697 11.35 0.000 1.137246 1.612223 L2. | .2000723 .2200332 0.91 0.363 -.2311849 .6313294 | _cons | -6.871725 17.42993 -0.39 0.693 -41.03377 27.29032 ------------------------------------------------------------------------------ . mat open = e(b)[1, "open:"] . mat open_varcov = e(V)["open:","open:"]
Then I tried to assign these matrices to an instrumental equation specified as bellow
Code:
reg (open L1.open L2.open L1.high L2.high L3.high) erepost b = open erepost open_varcov = e(V)["open:","open:"]
[P] error . . . . . . . . . . . . . . . . . . . . . . . . Return code 507
name conflict
You have issued a matrix post command, and the variance-
covariance matrix of the estimators does not have the same row
and column names, or if it does, those names are not the same
as for the coefficient vector.
(end of search)
name conflict
You have issued a matrix post command, and the variance-
covariance matrix of the estimators does not have the same row
and column names, or if it does, those names are not the same
as for the coefficient vector.
(end of search)
Thank you very much
0 Response to name conflict in identifying a matrix
Post a Comment