Spool comment in loops

For questions regarding programming in the EViews programming language.

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

eviewsnc
Posts: 7
Joined: Tue Nov 10, 2015 4:21 am

Spool comment in loops

Postby eviewsnc » Thu Jan 14, 2016 10:57 am

Hi all,

I am trying to use the description of each variable in a group as the comment in my spool. I know spool comments are normally inside inverted commas, is there any way to set the comment for a spool to be the description of a series?

Thanks

Code: Select all

for !i=1 to levels_real.@count %1 = levels_real.@seriesname(!i) graph graph_{%1} {%1} spool.append graph_{%1} spool.comment untitled0{!i} {{%1}.label(d)} spool.name untitled0{!i} {%1} next

EViews Jason
EViews Developer
Posts: 870
Joined: Tue Sep 16, 2008 3:50 pm

Re: Spool comment in loops

Postby EViews Jason » Thu Jan 14, 2016 12:09 pm

try

Code: Select all

%description = {%1}.@attr("Description") spool.comment untitled0{!i} {%description}

eviewsnc
Posts: 7
Joined: Tue Nov 10, 2015 4:21 am

Re: Spool comment in loops

Postby eviewsnc » Fri Jan 15, 2016 3:03 am

Thanks Jason,works perfectly!!


Return to “Programming”

Who is online

Users browsing this forum: No registered users and 2 guests