Dear all,
I'm trying to run an estimation of a model using GMM.
And I would be very grateful if someone can help me on this.
Problem is, the data are in time series, and I am having trouble in setting the moment equations.
response var: resv
independent vars: x1, x2, x3, x4, x5 c1
time series length = 20
observations = 20
proc model data=work.gmmtest;
parms a1 a2 a3 a4 a5 p r;
endogenous resv;
instruments x1 x2 x3 x4 x5 c1;
eq.m1= resv-p*lag(resv);
eq.m2= ....... ;
fit m1 m2 .... / gmm;
run; quit;
This is the code I used.
I put the first equation m1 that way since I was expecting an autocorrelation.
But, from there, I am not sure what to put as a moment condition here.
How should I set up the moment equation there?
The moment conditions depend on the formulation of your model. A simple model with a single moment condition which includes your 6 independent variables, 1 response variable, and an autocorrelated error term could be specified as:
proc model data=work.gmmtest;
parms a1 a2 a3 a4 a5 p r;
endogenous resv;
instruments x1 x2 x3 x4 x5 c1;
resvstruct = resv - (a1*x1 + a2*x2 + a3*x3 + a4*x4 + a5*x5 + r*c1);
eq.m1= resvstruct -p*lag(resvstruct);
fit m1 / gmm;
quit;
-Marc
The moment conditions depend on the formulation of your model. A simple model with a single moment condition which includes your 6 independent variables, 1 response variable, and an autocorrelated error term could be specified as:
proc model data=work.gmmtest;
parms a1 a2 a3 a4 a5 p r;
endogenous resv;
instruments x1 x2 x3 x4 x5 c1;
resvstruct = resv - (a1*x1 + a2*x2 + a3*x3 + a4*x4 + a5*x5 + r*c1);
eq.m1= resvstruct -p*lag(resvstruct);
fit m1 / gmm;
quit;
-Marc
Available on demand!
Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.
Learn how to run multiple linear regression models with and without interactions, presented by SAS user Alex Chaplin.
Find more tutorials on the SAS Users YouTube channel.