Page 1 of 1

for loop strings to group

Posted: Thu Feb 19, 2015 12:35 pm
by vytama
Hello,

Eviews 8 here. Instead of using "group all.add D1_series1 D1_series2 ..." where I would list all series, I wanted to use this command with string:

indicators = @rows(mnemonic_all)
for !i=1 to !indicators

%mnemonics=mnemonic_all(!i)

group all.add D1_{%mnemonics}
next
However, if I run it the group ends up with the last series only. Can you help me to figure out how to modify this code that it would append series in this group? Thank you.

Re: for loop strings to group

Posted: Thu Feb 19, 2015 5:16 pm
by EViews Gareth
Change:

Code: Select all

group all.add D1_{%mnemonics}
to be:

Code: Select all

all.add D1_{%mnemonics}