# Cointegration

Two nonstationary series are cointegrated if they tend to move together through time. For instance, we have established that the levels of the Fed Funds rate and the 3-year bond are non­stationary, whereas their differences are stationary. In the opaque language used in time-series
literature, each series is said to be “integrated of order 1” or I(1). If the two nonstationary series move together through time then we say they are “cointegrated.” Economic theory would suggest that they should be tied together via arbitrage, but that is no guarantee. In this context, testing for cointegration amounts to a test of the substitutability of these assets.

The basic test is very simple. Regress one I(1) variable on another using least squares. If the series are cointegrated, the residuals from this regression will be stationary. This is verified using augmented Dickey-Fuller test, with a new set of critical values that take into account that the series of residuals used in the test is estimated from data.

The null hypothesis is that the residuals are nonstationary, which implies that the series are not cointegrated. Rejection of this leads to the conclusion that the series are cointegrated. The coint function in gretl carries out each of the three steps in this test. First, it carries out a Dickey-Fuller test of the null hypothesis that each of the variables listed has a unit root. Then it estimates the cointegrating regression using least squares. Finally, it runs a Dickey Fuller test on the residuals from the cointegrating regression. This procedure, referred to as the Engle-Granger (EG) cointegration test and discussed in chapter 12 of Hill et al. (2011), is the one done in gretl by default. Gretl can also perform cointegration tests based on maximum likelihood estimation of the cointegrating relationships proposed by Johansen and summarized in Hamilton (1994, chapter 20). The Johansen tests use the coint2 command, which is explained in gretl’s documentation (Cottrell and Lucchetti, 2011, chapter 24).

Figure 12.8 shows the dialog box used to test cointegration in this way. To obtain it use Model>Time series>Cointegration test>Engle-Granger from the main gretl window. In the dialog box you have to indicate how many lags you want in the initial Dickey-Fuller regressions on the the variables, which variables you want to include in the cointegrating relationship, and whether you want a constant, trend, or quadratic trend in the regressions. Testing down from the maximum lag order is chosen via a check-box. To select these additional modeling options you’ll have to click on the down arrow button indicated in Figure 12.8. This will reveal the four choices:

test without constant

test with constant

with constant and trend

We are choosing the model that contains a constant, which is the default. For the 3-year bond rate and the Fed funds rate series we get the result shown in Figure 12.9.

Since the —skip-df option is used, there are only two steps shown in the output. The first is the outcome of the cointegrating regression. It is just a linear regression of b and a constant on f. The residuals are automatically generated and passed to step 2 that performs the EG test. The model selection occurs because the –test-down option is used, which picks a model with 3 lags. The test statistic and its p-value are circled at the bottom. The statistic is -4.32 and it is significant at the 5% level. The unit root null hypothesis is rejected and we conclude that the series are cointegrated.

The syntax and options available for the Engle-Granger test are summarized:

coir. t

Arg um ents: order depvar indepvars

Options: —nc [do not include a constant)

—ct (include constant and trend)

—ctt (include constant and quadratic trend)

—зкір-df (no DF tests on individual variables)

—test-down (automatic lag order)

If the specified lag order is positive all the Dickey-Fuller tests use that order, with this qualifi­cation: if the —test-down option is used, the given value is taken as the maximum and the actual lag order used in each case is obtained by testing down. Basically, a series of t-tests on the last lag is used until the last one becomes significant at 10% level.

The syntax for Engle-Granger tests from a script from the console follows

coint 4 f b —test-down —skip-df

Notice that a maximum of 4 lags are considered; the —test-down option will attempt to auto­matically reduce that number according to the algorithm discussed above. Also, we have chosen to skip the Dickey-Fuller tests for stationarity of f and b since they have already been done and discussed above.