Export list of variables and labels

For questions regarding the import, export and manipulation of data in EViews, including graphing and basic statistics.

Moderators: EViews Gareth, EViews Jason, EViews Steve, EViews Moderator

quark2001
Posts: 4
Joined: Tue Sep 19, 2017 3:49 am

Export list of variables and labels

Postby quark2001 » Wed Oct 25, 2017 7:25 am

Hello,

How could I export the list of all the variables in a wf, name and labels, into two columns of excel? I have seen a thread to export the list of the variables as a string, but I need also the labels.

And from a model, exporting all, or the exogeneous, or the endogeneous (name and labels)?

Thanks in advance

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

Re: Export list of variables and labels

Postby EViews Gareth » Wed Oct 25, 2017 7:34 am

For that specific formatting, you'd have to create a table object and loop through all the series, inserting their name and the attribute you're interested in into the table, then saving the table at the end.
Follow us on Twitter @IHSEViews

quark2001
Posts: 4
Joined: Tue Sep 19, 2017 3:49 am

Re: Export list of variables and labels

Postby quark2001 » Wed Oct 25, 2017 7:35 am

Thanks a lot.

Could you please give me an example on how to structure the loop (for example, for all the variables or selecting just the exogeneous)?

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

Re: Export list of variables and labels

Postby EViews Gareth » Wed Oct 25, 2017 7:39 am

Something like:

Code: Select all

%list = model.@endoglist
!i=1
for %j {%list}
   table(!i,1) = %j
   !i=!i+1
next
Follow us on Twitter @IHSEViews


Return to “Data Manipulation”

Who is online

Users browsing this forum: No registered users and 11 guests