Store ARDL regression order in a scalar?

For questions regarding programming in the EViews programming language.

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

dravenous
Posts: 33
Joined: Thu Jan 29, 2015 2:30 pm

Store ARDL regression order in a scalar?

Postby dravenous » Thu Mar 01, 2018 2:34 pm

Essentially I was wondering if I could get the order of my ARDL estimated equations into scalars so I could bulk test that the main RHS variable met a certain criteria. I have a large number of equations and I want to be able to loop through and flag when the main RHS variable coefficient is negative. The problem is with ARDL the spot of that variable depends on how many lags are chosen ,versus using regular LS where it's always the first coefficient in the coefficient vector. If I could extract the order of the ARDL I could tell my check where to look as it seems to always follow the pattern of LHS variable lags, RHS, RHS variable lags. TLDR:: if Eviews estimated an ARDL(2,2) can I get at that number in any straightforward programmatic way?

Thanks!

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

Re: Store ARDL regression order in a scalar?

Postby EViews Gareth » Thu Mar 01, 2018 2:45 pm

Easier to look up the RHS variable in the equation's varlist:

Code: Select all

=EQNAME.@coef(@wfind(EQNAME.@varlist, "RHSNAME")-1)
Follow us on Twitter @IHSEViews

dravenous
Posts: 33
Joined: Thu Jan 29, 2015 2:30 pm

Re: Store ARDL regression order in a scalar?

Postby dravenous » Thu Mar 01, 2018 2:57 pm

This worked wonderfully, thank you. SOO much more straight forward.


Return to “Programming”

Who is online

Users browsing this forum: Google [Bot] and 33 guests