Page 1 of 1

Dated data table- sample

Posted: Fri Sep 16, 2016 6:43 am
by tvonbrasch
Hi

I have a quarterly workfile and I want to create a dated data table so that annual series are shown every fifth year, e.g.
table.JPG
table.JPG (11.79 KiB) Viewed 3671 times
How can I do this?

Thomas

Re: Dated data table- sample

Posted: Fri Sep 16, 2016 9:23 am
by EViews Jason
There is no native way to do it. You will have to freeze the dated data table into a table and then manually remove the columns.

This isn't the most sophisticated bit of code but gets the job done.

Code: Select all

'for an annual workfile where the last observation ends in 0 or 5 (ex: 1990 or 1995) freeze(mytable, mode=overwrite) group01.dtable for !i=@obsrange to 0 step -1 if(@mod(@obsrange-!i,5)<>0) then !col = !i+1 mytable.deletecol(!col) endif next

Re: Dated data table- sample

Posted: Sun Sep 18, 2016 10:19 pm
by tvonbrasch
Hi

okey, thanks for this code!
Thomas