Day of the week effect - Analysis of OLS Regression

For questions regarding the import, export and manipulation of data in EViews, including graphing and basic statistics.

Moderators: EViews Gareth, EViews Steve, EViews Moderator, EViews Jason

rickyyml
Posts: 16
Joined: Tue Nov 05, 2013 1:58 am

Day of the week effect - Analysis of OLS Regression

Postby rickyyml » Mon Nov 18, 2013 8:23 am

Dear all EViews Expert

I am a new user of EView and I need to do "Day of the week effect" analysis for BSE Sensex with OLS Regression, 5 dummy variable to be set up for this analysis, but I really don't know how to do by EViews.

I learn from other post in this forum, the instruction below is for "Monday Effect"

series dummy2 = @recode(@datepart(@date,"w")=1,1,0)

Would you please advise how can I modify it so that I can fit for my analysis?

Or if it is not suitable, would you please advise me how the instruction should be?

I am using EView 8, and the workfile attached (the daily of the 10 years' index is in "drl".

Please kindly offer me your helping hand
Attachments
bse sensex.wf1
(167.38 KiB) Downloaded 432 times

EViews Glenn
EViews Developer
Posts: 2682
Joined: Wed Oct 15, 2008 9:17 am

Re: Day of the week effect - Analysis of OLS Regression

Postby EViews Glenn » Mon Nov 18, 2013 2:52 pm

If I'm understanding the question correctly:

Code: Select all

series monday = @weekday=1 series tuesday = @weekday=2 series sunday = @weekday=7

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

Re: Day of the week effect - Analysis of OLS Regression

Postby EViews Gareth » Mon Nov 18, 2013 3:08 pm

More details can be found here:
http://www.eviews.com/Learning/dummies.html

rickyyml
Posts: 16
Joined: Tue Nov 05, 2013 1:58 am

Re: Day of the week effect - Analysis of OLS Regression

Postby rickyyml » Mon Nov 18, 2013 6:19 pm

Dear Gareth

Thank you very much, I think it is what I need, and I will go though the learning material.

Thank you again kindly help and guiding.

rickyyml
Posts: 16
Joined: Tue Nov 05, 2013 1:58 am

Re: Day of the week effect - Analysis of OLS Regression

Postby rickyyml » Tue Nov 19, 2013 7:56 am

Dear Gareth and Glenn

After I go though the "Dummy variable", I have tried to do the analysis in my wordfile, but I don't know why no matter how I form the equation, still cannot get the result I need, the equation I tried are show below:

equation eql.ls r c weekday=1
equation eql.ls weekday=1 c r
equation eql.ls weekday=1 c weekday=2 weekday=3 weekday=4 weekday=5
equation eql.ls weekday=2 weekday=3 weekday=4 weekday=5 c weekday=1
equation eql.ls r c weekday=1 weekday=2 weekday=3 weekday=4 weekday=5
equation eql.ls weekday=1 weekday=2 weekday=3 weekday=4 weekday=5 c r

In fact, I got the offical result for the calculation (as attached file "Table"), and I am able to calculate indentical result for descriptive statistics (as in Table 1), so I am sure the the data and calculation of return is no problem, but no mater how I form the equation, still cannot the get the result as Table 3.

Would you please kindly advise how should I revise the equation so that I can get the result?

Thank you in advance.
Attachments
Table.jpg
Table.jpg (217.81 KiB) Viewed 11451 times
bse sensex.wf1
(189.44 KiB) Downloaded 342 times

EViews Glenn
EViews Developer
Posts: 2682
Joined: Wed Oct 15, 2008 9:17 am

Re: Day of the week effect - Analysis of OLS Regression

Postby EViews Glenn » Tue Nov 19, 2013 1:05 pm

There's something missing in your description of the regression results. With no other regressors, the coefficients should equal the by-means.

rickyyml
Posts: 16
Joined: Tue Nov 05, 2013 1:58 am

Re: Day of the week effect - Analysis of OLS Regression

Postby rickyyml » Tue Nov 19, 2013 6:11 pm

Dear Glenn

Thank you for your quick respond.

Since I am not sure which part of missing, I hereby attached the literature for your reference.

Please kindly help to advise.

Thank you so much!
Attachments
literature.pdf
(136.8 KiB) Downloaded 507 times

EViews Glenn
EViews Developer
Posts: 2682
Joined: Wed Oct 15, 2008 9:17 am

Re: Day of the week effect - Analysis of OLS Regression

Postby EViews Glenn » Tue Nov 19, 2013 6:35 pm

They do say they are running a regression of dummy variables on the 5-day data, but as I said, the results should equal the by-means, and it does not appear that this is the case.

I have no idea what they are doing.

rickyyml
Posts: 16
Joined: Tue Nov 05, 2013 1:58 am

Re: Day of the week effect - Analysis of OLS Regression

Postby rickyyml » Tue Nov 19, 2013 7:08 pm

Dear Glenn

If I take Monday as variable, would it be:

1. The coefficient of Monday return with total return of the 10 year period (Monday to Friday)

OR

2. The coefficient of Monday return with Tuesday to Friday

Would you please advise if I need to calculate the above two, how should I form the equation?

And I found a equation from other post in the Forums also for "Day of the week effect" as below:
arch(1,1) r c @ @expand(@weekday,@droplast)

Would it be amended to fit for my case?

Thank you.

EViews Glenn
EViews Developer
Posts: 2682
Joined: Wed Oct 15, 2008 9:17 am

Re: Day of the week effect - Analysis of OLS Regression

Postby EViews Glenn » Tue Nov 19, 2013 8:37 pm

I'm sorry but I don't understand the questions.

rickyyml
Posts: 16
Joined: Tue Nov 05, 2013 1:58 am

Re: Day of the week effect - Analysis of OLS Regression

Postby rickyyml » Tue Nov 19, 2013 9:34 pm

Dear Glenn

Thank you, and I will learn more for this topic and seeking for your help again.


Return to “Data Manipulation”

Who is online

Users browsing this forum: No registered users and 1 guest