Page 1 of 1

FGLS Question

Posted: Tue Jun 30, 2015 6:40 pm
by diggetybo
My textbook has a question I've been trying to crack for days. I can't match the books output results for using FGLS to quasi-difference as a correction for serial correlation in the errors. The regressors are assumed to be strictly exogenous.

I have at least reproduced the book's OLS output:
dependent variable: log(chnimp)
c=-17.80
log(chempi)=3.12
log(gas)=0.20
log(rtwex)=0.98
befile6=0.06
affile6=-0.03
afdec6=-0.57

R-squared = .305
From here I saved the residuals, then used them for the auxiliary regression of errors on the lag of errors. From here I saved the fitted values as an estimate of ro (autocorrelation). My FGLS weight in Eviews is: (1-(ro_hat^2))^.5

However my FGLS results are basically the same as OLS, the books PW results are markedly different:

dependent variable: log(chnimp)
c=-37.08
log(chempi)=2.94
log(gas)=1.05
log(rtwex)=1.13
befile6=-.02
affile6=-.03
afdec6=-.58

R-squared= .202

I attached the workfile, if anyone manages to match the book or catch a mistake.

Re: FGLS Question

Posted: Tue Jun 30, 2015 8:57 pm
by startz
Is your ro_hat a single number or a series of different numbers?

Re: FGLS Question

Posted: Tue Jun 30, 2015 10:09 pm
by diggetybo
I tried as a single entry in scalar form via the coefficient of u_hat on u_hat(-1), and I also tried as a series, neither way seems to match the book's answer. I've been looking at this for too long maybe, I can't seem to spot the problem heheh.

Re: FGLS Question

Posted: Wed Jul 01, 2015 4:40 am
by trubador
PW is an iterative procedure, where you estimate rho until it converges. Your FGLS weight is just a fixed coefficient that PW uses to make a transformation of the initial observation. Unless you want to write a code for the procedure, you can use the following command:

Code: Select all

equation pw.ls(arma=gls, optmethod=opg) log(chnimp) c log(chempi) log(gas) log(rtwex) befile6 affile6 afdec6 ar(1)

Re: FGLS Question

Posted: Wed Jul 01, 2015 7:52 am
by diggetybo
Yes, that did the trick! Thank you to you guys for helping me out. It's making a lot more sense now.