Anual estimation of weekly data

For questions regarding programming in the EViews programming language.

Moderators: EViews Gareth, EViews Moderator, EViews Jason, EViews Matt

Kouvas
Posts: 34
Joined: Sat Aug 31, 2013 3:28 am

Anual estimation of weekly data

Postby Kouvas » Thu Apr 10, 2014 10:38 am

Hello there

I have a large dataset of firms with weekly data on stock prices. I want to estimate a yearly regression for each firm. Is there any code to do that (i.e. using the smpl command)? Thanks in advance!

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

Re: Anual estimation of weekly data

Postby EViews Gareth » Thu Apr 10, 2014 11:38 am

Could you be a bit more explicit as to what you're trying to do?

Kouvas
Posts: 34
Joined: Sat Aug 31, 2013 3:28 am

Re: Anual estimation of weekly data

Postby Kouvas » Tue Apr 15, 2014 5:37 am

I am trying to estimate yearly regressions using weekly data. Therefore, in each year I will have a large number of weeks (the number of weeks depends on the year). I am using the smpl command to update the sample for each year (for example year 2007 should ran using the command smpl !year !year where !year=2007). Is there an alternative way to do that?

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

Re: Anual estimation of weekly data

Postby EViews Gareth » Tue Apr 15, 2014 9:25 am

Not really, you'll have to use samples.

Kouvas
Posts: 34
Joined: Sat Aug 31, 2013 3:28 am

Re: Anual estimation of weekly data

Postby Kouvas » Tue Apr 15, 2014 9:51 am

Thanks for the prompt answer. Therefore I have to create samples for example using the command sample mysample1990 1990 1990 should create a sample that when used in weekly data includes all the weeks in 1990?

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

Re: Anual estimation of weekly data

Postby EViews Gareth » Tue Apr 15, 2014 9:56 am

Yes

Kouvas
Posts: 34
Joined: Sat Aug 31, 2013 3:28 am

Re: Anual estimation of weekly data

Postby Kouvas » Tue Apr 15, 2014 10:03 am

This provides a sample that includes the last week of the previous year. However if I use the comand sample mysample1999 1999+1 1999 then it creates the right sample. Is this something I should expect?

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

Re: Anual estimation of weekly data

Postby EViews Gareth » Tue Apr 15, 2014 10:35 am

EViews views a week as being in a year if any day of that week was in that year.


Return to “Programming”

Who is online

Users browsing this forum: No registered users and 2 guests