Page 1 of 1

rolling regression program

Posted: Tue Sep 20, 2011 9:42 am
by justynaka2187
Hello,
I was hoping if any of you could help me with my problem. I am quite new to eviews programing but i managed to program rolling regression for my forecast, but when i run it i the results I am getting are pretty strange, firstly the equation I am getting has very large (in absolute terms) t statistics and my R^2 ( also adjusted ) is equall to 1 , then when i do the forecast from this equation I m just getting back 3 dots in the graph coresponding to one date, also I dont get statistics like MAE etc back. Here is the program I am using:
smpl @all
scalar n =@obs(hml)
scalar window = 60
series hml
equation e
for !i=0 to n-window-1
smpl @first+!i @first+!i+window-1
e.ls hml c erp tb3m yieldspr(-1) defspr credspr(-2)
smpl @first+!i+window @first+!i+window
hml =@coefs(1) +@coefs(2)*erp + @coefs(3)*tb3m +@coefs(4)*yieldspr(-1) + @coefs(5)*defspr +@coefs(6)*credspr(-2)
next
delete window n

I would highly appreciate if any of you could help me!
Thanks!

Re: rolling regression program

Posted: Tue Sep 20, 2011 9:49 am
by EViews Gareth
There's a few things in there that don't make sense to me.

1) The line that says:

Code: Select all

series hml

This line would usually be used to declare a new (empty) series. However in your case, I suspect that there is already a series called HML (since you've used it in the @obs function above). Thus this line does nothing, I suspect.

2) The line where you're doing your forecast. You appear to be assigning the forecast value on top of the actual data value. This is almost certainly not what you wanted to do.

Perhaps you meant to assign the forecasts to a new series, called something else. So perhaps your program should be:

Code: Select all

smpl @all
scalar n =@obs(hml)
scalar window = 60
series hml_f
equation e
for !i=0 to n-window-1
smpl @first+!i @first+!i+window-1
e.ls hml c erp tb3m yieldspr(-1) defspr credspr(-2)
smpl @first+!i+window @first+!i+window
hml_f =@coefs(1) +@coefs(2)*erp + @coefs(3)*tb3m +@coefs(4)*yieldspr(-1) + @coefs(5)*defspr +@coefs(6)*credspr(-2)
next
delete window n


I don't see anywhere that you're calculating MAE, so that's probably why you're not seeing it.

Re: rolling regression program

Posted: Tue Sep 20, 2011 10:38 am
by justynaka2187
Thank you so much for your reply, as said I am quite new to programming in Eviews therefore I couldn't spot the mistake I was doing. So again thank you for your help, could you tell me how do I include the formula to calculate the forecast statistics in this program?

Re: rolling regression program

Posted: Thu Feb 18, 2016 12:23 pm
by Rolando Eduardo
Hi
I am doing a web application to forecast data, local environment makes good operation command execution, but when we built a site using IIS with OS Windows Server, at the time of prognosis in this distributed environment sends an error message , below:

"GetApplication Could not create instance of EViews Application object"

in some other forecasts and sent me the following message

Retrieving the COM class factory for component With CLSID {1B262E94-366E-4EB5-90A8-0A74B5B56B48} failed due to the following error: 80070005 Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED)) .- The directory exists-exists-file was written File- I enter the conditional


Rolando Eduardo

Re: rolling regression program

Posted: Thu Feb 18, 2016 12:25 pm
by EViews Gareth
email support@eviews.com along with your EViews serial number.

Re: rolling regression program

Posted: Fri Feb 19, 2016 4:30 pm
by Rolando Eduardo
I have a trial version, I'm developing in .NET and I forecast the error occurred (1) to want to evaluate Web service, we are very confident in the results forecast EVIEWS, and established interface with EVIEWS from .net, only we have yet this error, if the error had we can buy eviews, Greetings

Re: rolling regression program

Posted: Fri Feb 19, 2016 5:05 pm
by EViews Gareth
EViews Gareth wrote:email support@eviews.com along with your EViews serial number.