Dear Eviews,
I would suggest to create function, which would create a group of variables from equation on which this group depends. This is sort of a mix of functions "makeregs" and "@depends". What I mean?
Assume you have an equation:
equation1.ls INFLATION INFLATION(-1) INFLATION(-2) CRUDEOIL CRUDEOIL(-1) CRUDEOIL(-2) @during("2008m12") @trend
New function, let's call it "makedepends", would create a group of the following variables: INFLATION CRUDEOIL @during("2008m12") @trend
i.e. only those variables, on which equation depends on!
Unlike "makeregs" function, new function eliminates all possible lags. (Imagine rich ARDL model, which determines lags automatically, and using programming it's difficult to extract only variables which "makeregs" depends on)
Another way would be to use the function "@depends" in equation1 to extract variables on which this group depends on. For example, let's make group of regressors "mygroup", then make a string of depends using @depends and transform the string to a new group, as I show below:
equation1.makeregs mygroup
string mystring = mygroup.@depends
group group_{mystring}
But I find the function "@depends" a bit weird. Why?! because in case of equation1, the result would the following group:
group_inflation INFLATION INFLATION INFLATION CRUDEOIL CRUDEOIL CRUDEOIL @during("2008m12") @trend
I mean, why I need series INFLATION and CRUDEOIL 3xtimes in one group?!
Possibility to create group of "depends" variables from equation
Moderators: EViews Gareth, EViews Moderator
-
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13401
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Possibility to create group of "depends" variables from equation
Neat idea.
Follow us on Twitter @IHSEViews
Re: Possibility to create group of "depends" variables from equation
But what about to implement?! :))Neat idea.
-
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13401
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Possibility to create group of "depends" variables from equation
It will be in the next major release
Follow us on Twitter @IHSEViews
Re: Possibility to create group of
Gareth, thank you!It will be in the next major release
I have 2 more things in the same context. Gareth, could you please to have a look at this?
1. The FIRST
I have tried to extract series from the "makeregs" group and then using @depends function to obtain series, but something doesn't work. Look at the following code using "equation1" from the post above:
Code: Select all
{%equation}.makeregs gr_regs ' make regressors group
%str_regs = gr_regs.@depends ' create string of dependent vars
group gr_{%str_regs} ' create a group of dependent vars
%depreg = gr_{%str_regs}.@seriesname(1) ' make a string of the first series in the group of dep.vars
show {%depreg} 'show the first variable in the group of dep.vars
2. The SECOND
About the sequence of variables in the output of ARDL model. Assume ARDL model:
Code: Select all
EQ1.ardl(fixed, deplags=2, reglags=1) LOG(HICP) LOG(WAGESA) LOG(FOOD) @DURING("2005m07")
LOG(HICP) LOG(HICP(-1)) LOG(HICP(-2)) LOG(WAGESA) LOG(WAGESA(-1)) LOG(FOOD) LOG(FOOD(-1)) @DURING("2005m07")
Everything is fine. The sequence of variables is the same in both equation and output.
But if I define EQ1 with fixed lags using @fl() function the sequence of variables changes. Here is equation:
Code: Select all
EQ1.ardl(fixed, deplags=2, reglags=1) LOG(HICP) @FL(LOG(WAGESA),0) LOG(FOOD) @DURING("2005m07")
LOG(HICP) LOG(HICP(-1)) LOG(HICP(-2)) LOG(FOOD) LOG(FOOD(-1)) LOG(WAGESA) @DURING("2005m07")
Note that using @fl() function, the variable LOG(WAGESA) goes after LOG(FOOD).
From programming point of view it's disappointing, so I cannot keep the sequence ov variables defining equation and defining the group of variables in this equation.
Is it possibel to fix it?
-
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13401
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Possibility to create group of "depends" variables from equation
1) %str_regs has a space in it, so can't be used as a variable name.
2) Unfortunately not.
2) Unfortunately not.
Follow us on Twitter @IHSEViews
Re: Possibility to create group of "depends" variables from equation
1) OK I see. I overcome it by using string vector and split string in parts.
2) I hope a new "makedepends" function will fix it ...
2) I hope a new "makedepends" function will fix it ...
Re: Possibility to create group of
Gareth, have you managed to introduce this function in Eviews12 we talked a year ago?It will be in the next major release
Andrejs
Re: Possibility to create group of "depends" variables from equation
Is it still in a pipeline?
Andrejs
Andrejs
-
- Fe ddaethom, fe welon, fe amcangyfrifon
- Posts: 13401
- Joined: Tue Sep 16, 2008 5:38 pm
Re: Possibility to create group of "depends" variables from equation
Actually, I take it back - it is in EViews 12.
Code: Select all
eqname.@depends
Follow us on Twitter @IHSEViews
Re: Possibility to create group of "depends" variables from equation
Great. thanks!
Even though the function doesn't reflect dummies [@during()] and trend (@trend). I would add them.
Even though the function doesn't reflect dummies [@during()] and trend (@trend). I would add them.
Return to “Suggestions and Requests”
Who is online
Users browsing this forum: No registered users and 2 guests