MULTIPLEBREAKS—Breaks based upon threshold

Use this forum to post complete RATS "procedures". Please be sure to include instructions on using the procedure and detailed references where applicable.
TomDoan
Posts: 7728
Joined: Wed Nov 01, 2006 4:36 pm

MULTIPLEBREAKS—Breaks based upon threshold

Unread post by TomDoan »

@MultipleBreaks does multiple change point calculations on a linear model using a threshold variable other than time.

Detailed description

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}
Ana_Rita
Posts: 13
Joined: Fri Apr 06, 2012 10:07 am

THRESHTEST - Regression with threshold breaks

Unread post by Ana_Rita »

TomDoan wrote:There's really no good way to modify @THRESHTEST, since it uses LM calculations to keep the computing time down. It would be easier to modify @MULTIPLEBREAKS. That does calculations based upon calculations of the regressions across each regime. Instead of keeping track of the sum of squared residuals for each interval:

compute intervalrss(s,e)=%rss

you would keep track of (minus the) subsample log likelihoods (since it's written to do a minimization rather than a maximization):

compute intervalrss(s,e)=%nobs=(e-s+1),+.5*%nobs*(log(%rss/%nobs)+1)

That will figure out the optimal regime breaks; you'll have to figure out how to adapt the output to handle the log likelihood
Hi Tom,

Since i want to perform the @THRESHTEST assuming heteroscedasticity and using one of the regressors as the threshold variable, i followed your advice and modified the procedure (attached). The output gives me RSS for 0 and 1 break, and according to BIC it finds one break to be the best (also, the break values output gives NA...not sure why).

In order to now adapt this result to get the Hansen test allowing for heteroscedastic errors, i believe i need to use the value i got for RSS from the @MULTIPLEBREAKS test (which is 0.756) so that in the @THRESHTEST procedure instead of having:

Code: Select all

*  Convert everything to F statistics
*
compute sigma = (%rss-ssqmax)/(%nobs-2*%nreg)
compute fmax  = (ssqmax/%nreg)/sigma
set ftests nb ne = (ssq/%nreg)/sigma
I would have something like:

Code: Select all

*  Convert everything to F statistics
*
compute sigma = (0.756-ssqmax)/(%nobs-2*%nreg)
compute fmax  = (ssqmax/%nreg)/sigma
set ftests nb ne = (ssq/%nreg)/sigma
This would then give me the corrected likelihood ratio. According to Hansen's paper the bootstrap technique under heteroscedastic errors also needs to be modified, could you please give some advice on how to do that?

I appreciate any help you can provide me with this!!

Many thanks!
Ana
Attachments
multiplebreaksmod.src
(6.19 KiB) Downloaded 1168 times
e1983
Posts: 20
Joined: Sun Aug 28, 2011 2:32 am

MULTIPLEBREAKS procedure (revised) Question

Unread post by e1983 »

Hi. Is it possible to get confidence intervals around the break points?
TomDoan
Posts: 7728
Joined: Wed Nov 01, 2006 4:36 pm

Re: MULTIPLEBREAKS procedure (revised) Question

Unread post by TomDoan »

e1983 wrote:Hi. Is it possible to get confidence intervals around the break points?
Not that I'm aware. The calculations of those in Bai-Perron rely on the fact that the potential break locations in that are equally spaced.


Last bumped by TomDoan on Thu Jun 05, 2025 8:52 am.
Post Reply