Function to get the name (not label) of a series as a str?
Posted: Wed Sep 02, 2015 2:42 pm
Is there a function that, given a series, returns the name of the series as a string? I can write
to get the label of the series, but given a series, is there a function that will return its name as a string? For example,
would display
regardless of what the series are labeled. This post https://estima.com/forum/viewtopic.php? ... ries#p4936 mentions that there is a difference between series names and series labels, but I'm not sure how to get the former into a string variable.
Code: Select all
compute [string] series_label = %l(gdp)
Code: Select all
dofor s = gdp cons gce gov
compute [string] series_name = FUNCTION(s)
display series_name
end dofor s
Code: Select all
gdp
cons
gce
gov