Page 1 of 1

series transformation

Posted: Tue Feb 22, 2011 6:30 am
by ercan
I have 20 different series in a workfile. And I'd like to generate 4 period movibg averages of tehse series in a new page without having to do it one by one. for example, for series 1 named x i write the follwing code:

series xm=@movav(x,4)

this procedure only creates teh ma of series x. Can I write a loop to generate ma of 20 series?

Re: series transformation

Posted: Tue Feb 22, 2011 8:59 am
by EViews Gareth
Put them in a group, then write a loop based on the group.

Code: Select all

group g x '..... all other series here for !i=1 to g.@count %name = g.@seriesname(!i) %newname = %name + "m" series {%newname} = @movav({%name}, 4) next

Re: series transformation

Posted: Tue Feb 22, 2011 9:42 am
by ercan
I copied the code in the command space. when i run it i get "flow of control statement executed from the comamnd line" error message.

Re: series transformation

Posted: Tue Feb 22, 2011 10:06 am
by EViews Gareth
You have to run it in a program (file->new->program).

cross correlation

Posted: Fri Feb 25, 2011 8:39 am
by ercan
Is there a way to extract lead and lag cross correlation coefficients for multiple series? I have 10 distinct series which I would like to compute cross correlation against a series without doing it manually one by one.