The following is an example. This uses the same data set as the Hansen ECM 1996 threshold autoregression replication.
- Code: Select all
open data gnp.asc
calendar(q) 1947
data(format=free,org=columns) 1947:01 1990:03 gnp dontknow
*
set ggrowth = log(gnp/gnp{1})*400.0
*
@tar(laglist=||1,2,5||,nreps=1000) ggrowth
set lagtwo = ggrowth{2}
@multiplebreaks(thresh=lagtwo,max=3) ggrowth
# constant ggrowth{1 2 5}
