Recursive least square estimation

For technical questions regarding estimation of single equations, systems, VARs, Factor analysis and State Space Models in EViews. General econometric questions and advice should go in the Econometric Discussions forum.

Moderators: EViews Gareth, EViews Moderator

auvernois
Posts: 3
Joined: Thu Aug 16, 2012 10:45 am

Recursive least square estimation

Postby auvernois » Thu Aug 16, 2012 11:06 am

Hi,

I'm doing a simple OLS regression, and I'd like to estimate and store coefficients recursively, using either an anchored or a rolling estimation period.
I know I could do this into a loop, but it seems that I could do it faster using the "rls" function.
So far, I'm doing this:
equation eq1.ls log(ser1/ser1(-60)) = c(1) + c(2) * log(ser2/ser2(-60))
eq1.rls(c)
2 questions:
- It seems that this "rls" function is using an anchored estimation period, am I right ? Can we use it with a rolling window ?
- The coefficients are plotted on a graph ,but I can't find the underlying series, how do I retrieve them (I actually do not need the chart, just the series).

Thanks :D

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13604
Joined: Tue Sep 16, 2008 5:38 pm

Re: Recursive least square estimation

Postby EViews Gareth » Thu Aug 16, 2012 11:10 am

RLS won't do what you want. However there are numerous examples of doing rolling regression here on the forum, plus there is an EViews add-in that does it.

auvernois
Posts: 3
Joined: Thu Aug 16, 2012 10:45 am

Re: Recursive least square estimation

Postby auvernois » Thu Aug 16, 2012 11:30 am

Thanks for your quick answer :D !
Actually, I think my explanation wasn't that clear, because I think "rls" would do what I want.
I'd like to simulate doing this regression everyday for the past 50 years, and construct series of coefficients that do not contain forward looking data (coef at time t is computed by doing the regression on a sample that includes only information known up to time t, and so on).
I tried again and replaced rls(c) by rls(c,s) and it seems to be working: I have my series R_C1 and R_C2 with the 2 coefficients over time.
Am I wrong or using this rls function is the equivalent of doing ls regressions in a loop, expanding the estimation sample by a day at each iteration, and storing the coefficients in time series ?
Thanks

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13604
Joined: Tue Sep 16, 2008 5:38 pm

Re: Recursive least square estimation

Postby EViews Gareth » Thu Aug 16, 2012 11:49 am

RLS won't do rolling, only anchored.

So your description of what it is doing is correct, but if you want rolling, not anchored, you'll have to use rolling regression.

auvernois
Posts: 3
Joined: Thu Aug 16, 2012 10:45 am

Re: Recursive least square estimation

Postby auvernois » Thu Aug 16, 2012 12:04 pm

OK. I'll just stick with anchored for now.
Many thanks.


Return to “Estimation”

Who is online

Users browsing this forum: No registered users and 2 guests