Dear All,
I am estimating a spatial IV model using the files that you can download from here. They include the data file and the shp.dta file.
I generate a simple distance matrix:
Then, I would like to estimate the following model:
Unfortunately, I get the following error message:
I cannot understand why, since the two instruments are not included in the set of regressors of the main equation. Even worse, the estimation of the following model is fine:
But, if I try to estimate:
I get the same error message as before. So, apparently, the problem is with that variable. But it does not appear elsewhere in the estimation. Moreover, I checked if by chance it was a duplication of any other variable used in the analysis, but this is not the case. So, do you have any explanation about this issue? It is really puzzling.
EDIT:
if I do not consider any spatial correlation and I estimate:
The estimation goes through with the (correct) specification that the equation is exactly identified.This leads me to think that possibly it is a problem with spivregress? But which kind of problem?
Thanks in advance
SECOND EDIT:
I tried to estimate the above model using spivreg, rather than spivregress. Still I receive an error message, about missing values in the variable. In fact for the variable literacy I have 67 observations rather than 69. Could be this the reason of the error message above?
I am estimating a spatial IV model using the files that you can download from here. They include the data file and the shp.dta file.
I generate a simple distance matrix:
Code:
spset, modify coordsys(latlong, kilometers) spmatrix create idistance dW, replace
Code:
spivregress yp9500 (pc_culture=pc_institutions literacy1880) urb_rate1850 school countryname*, het dvarlag(dW)
Code:
equation not identified; must have at least as many instruments not in the regression as there are instrumented variables
Code:
spivregress yp9500 (pc_culture=pc_institutions) urb_rate1850 school countryname*, het dvarlag(dW)
But, if I try to estimate:
Code:
spivregress yp9500 (pc_culture=literacy1880) urb_rate1850 school countryname*, het dvarlag(dW)
I get the same error message as before. So, apparently, the problem is with that variable. But it does not appear elsewhere in the estimation. Moreover, I checked if by chance it was a duplication of any other variable used in the analysis, but this is not the case. So, do you have any explanation about this issue? It is really puzzling.
EDIT:
if I do not consider any spatial correlation and I estimate:
Code:
ivreg2 yp9500 (pc_culture=litt) pc_institutions urb_rate1850 school, r first
Thanks in advance
SECOND EDIT:
I tried to estimate the above model using spivreg, rather than spivregress. Still I receive an error message, about missing values in the variable. In fact for the variable literacy I have 67 observations rather than 69. Could be this the reason of the error message above?
Comment