Getting groups into strings

For questions regarding programming in the EViews programming language.

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

Posts: 16
Joined: Tue Sep 30, 2008 4:19 am

Getting groups into strings

Postby neilblake » Fri Jun 25, 2010 4:18 am

I have a group and I want to get it into a string so that I can loop through the elements of the group. e.g. something like this:

group test1 x1 x2 x3
string test2="test1"

for %t {test2}
series {%t}=1

but I can't use a group to create a string (i.e. string test2="test1" doesn't work it creates a string with test1 in it rather than the elements of test1). Is there anyway that I can get this to work or any otehr way that I can loop through the elements of a group?

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

Getting groups into strings

Postby EViews Gareth » Fri Jun 25, 2010 8:21 am

I'm not in the office to check, but I think you can use

Code: Select all

%s = group.@wmembers
Check the first few pages of the group entry in the Object Reference for it's string data members.
Follow us on Twitter @IHSEViews

Return to “Programming”

Who is online

Users browsing this forum: No registered users and 12 guests