TSMT 2.1: Estimation of Series with Multiple Structural Breaks

Example: GAUSS Sbreak procedure

This example follows the empirical application of Bai and Perron (2003). Below we use the GAUSS sbreak procedure to estimate breaks in the mean of the US expost real interest rate. The first step is to directly load the quarterly series of the three-month treasury bill provided in the file real.dat:
``````//Load TSMT library
library tsmt;

//Specify regressors
//Time varying coefficients in z
z = ones(rows(y),1);

//No time invariant regressors
x = 0;``````
Next we declare and initialize the structural break control structure and set model specific parameters:
``````//Declare sbControl structure
struct sbControl sbc0;

//Initialize instance of structure
sbc0 = sbControlCreate();``````
Then we specify the model parameters:
``````//Number of regressors subject to change
sbc0.q = 1;

//Number of structural changes
sbc0.m = 5;

//Trimming percentage
sbc0.trim = 0.15;

//Minimum length of segment (h > p + q)
sbc0.h = 0;

//Print iteration output
sbc0.printOutput = 1;

//Maximum number of iterations
sbc0.maxIters = 40;``````
Finally we declare the output structure and call the sbreak procedure:
``````//Declare output structure
struct sbOut SBout;

//Estimate model
SBout = sbreak(y,z,x,sbc0);``````
Which prints out the following report.
``````Global optimization of structural change model

The model with    1 breaks has SSR :      644.99552
The dates of the breaks are:
79

The model with    2 breaks has SSR :      455.95018
The dates of the breaks are:
47
79

The model with    3 breaks has SSR :      445.18186
The dates of the breaks are:
24
47
79

The model with   4 breaks has SSR :       444.87975
The dates of the breaks are:
24
47
64
79

The model with  5 breaks has SSR :        449.63949
The dates of the breaks are:
16
31
47
64
79``````

Have a Specific Question?

Get a real answer from a real person

Need Support?

Get help from our friendly experts.