How can I name an equation after a value in an alpha variable instead of e1, e2, e3... see program below:
spool myspool
for !i=1 to 134
smpl if @crossid = !i
equation e{!i}
e{!i}.ls ssu c price acv items promoacv promounits @trend(1) @expand(period,@dropfirst) easter
myspool.append e{!i}.stats
next
I would like my regressions to be named after the first value in a variable named "COT" instead of e1, e2, e3...
Naming Variables in Loop
Moderators: EViews Gareth, EViews Jason, EViews Moderator, EViews Matt
-
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13319
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Naming Variables in Loop
Here you go:
Where ALPHA is the name of the alpha series.
Code: Select all
spool myspool
series obsnum = @obsnum
for !i=1 to 134
smpl if @crossid = !i
%cxname = alpha(@min(obsnum))
%eqname = "e_" + %cxname
equation {%eqname}.ls ssu c price acv items promoacv promounits @trend(1) @expand(period,@dropfirst) easter
myspool.append {%eqname}.stats
next
Where ALPHA is the name of the alpha series.
Follow us on Twitter @IHSEViews
Who is online
Users browsing this forum: No registered users and 42 guests