I am using Eviews 7 and trying to estimate a panel threshold regression with the threshold value changing within an interval. So I ran the first equation with the threshold value at z=5 as:
equation eq5.LS(?,WGT=CXDIAG,COV=CXWHITE,NODF,UNBALSUR) y y(-1) x1*(z>5) x1*(z<5) x2*(z>5) x2*(z<5) z*(z>5) z*(z<5)
now I want to write a program that will estimate this equation and repeat 100 times, each time increasing the threshold by 1, that is the next equation would look like
eq6.LS(?,WGT=CXDIAG,COV=CXWHITE,NODF,UNBALSUR) y y(-1) x1*(z>6) x1*(z<6) x2*(z>6) x2*(z<6) z*(z>6) z*(z<6)
and the third would change the 6 to 7 and so on.
Any help with this would be much appreciated.
Thanks
panel threshold regression
Moderators: EViews Gareth, EViews Moderator, EViews Jason, EViews Matt
-
EViews Glenn
- EViews Developer
- Posts: 2682
- Joined: Wed Oct 15, 2008 9:17 am
Re: panel threshold regression
Something like
As an aside, shouldn't one of your inequality comparisons be a "or equal" comparison?
Code: Select all
for !i=5 to 100
equation eq!i.LS(?,WGT=CXDIAG,COV=CXWHITE,NODF,UNBALSUR) y y(-1) x1*(z>!i) x1*(z<!i) x2*(z>!i) x2*(z<!i) z*(z>!i) z*(z<!i)
next
Re: panel threshold regression
Thanks a million, it worked!
The only hitch now is that when the program runs it does not close the window of the individual equations it opens and so the program stops after a while and says "too many windows open". Is there a command I can insert to get it to close the equation window after each equation is estimated?
Thanks
The only hitch now is that when the program runs it does not close the window of the individual equations it opens and so the program stops after a while and says "too many windows open". Is there a command I can insert to get it to close the equation window after each equation is estimated?
Thanks
Who is online
Users browsing this forum: No registered users and 2 guests
