300 Investigating Economic Trends and Cycles
should be equal at the joints, which are described as the knots or the nodes. Breaks
can be accommodated within such a spline by placing successive nodes in close
proximity. Considerable effort has been devoted to developing algorithms that will
ensure the optimal placement of the nodes. (See, for example, Luo and Wahba,
1997.)
When the abscissae of the nodes correspond to the sample dates, it is possible to
increase the flexibility of the spline function by allowing local variations to occur
in the smoothing parameter. The same recourse can be used to lend additional
flexibility to the HP filter, which is a device that is appropriate for extracting from
noisy data a trend that is generated by a discrete-time process or by a process limited
in frequency to the Nyquist value.
The finite-sample version of the HP filter is provided by equation (6.124). Its
generalization is provided by:
x=y−Q(%−^1 +Q′Q)−^1 Q′y, (6.168)
where%=diag{λ 0 ,λ 1 ,...,λT− 3 }is a diagonal matrix of smoothing parameters and
Q′is the matrix of the twofold difference operator. In modifying the underlying
statistical model of the HP filter, which is specified by (6.129), it is the variance
σδ^2 of the process driving the trend that is allowed to vary, whereas the vari-
anceση^2 of the process that is responsible for the errors of observation remains
constant.
Setting%−^1 =λ−^1 Iin (6.168), which gives the smoothing parameter a globally
constant value, produces the HP filter. Settingλtto a high value where the trend
should be stiff and allowing it to take low values where the trend should be flexible
will produce a device that can easily absorb structural breaks.
On the assumption that the underlying trend process is limited in frequency by
the Nyquist value, it is appropriate to use the method of Fourier interpolation to
create a continuous trend based on the elements of the vectorx.
Example An example of a function that fails to accommodate structural breaks
is provided by the polynomial of degree 4 that has been interpolated through the
logarithms of 129 annual observations of the real GDP of the UK. This is shown in
Figure 6.21. Figure 6.22 shows the residual sequence. In both figures, three major
events can be recognized. The first is the end of World War I in 1918, which is
followed by a sharp decline in GDP. The second is the recession of 1929 and the
third is the end of World War II, which is also succeeded by a reduction in income.
The recession has less of an impact than one might expect.
Figure 6.23 shows a trend function that has been fitted using a variable smooth-
ing parameter. In this case, only the end-of-war breaks have been accommodated,
leaving the disruptions of the 1929 recession to be expressed in the residual
sequence. The effect has been achieved by attributing a greatly reduced value to
the smoothing parameter in the vicinity of the post-war breaks. In the areas that
are marked by shaded bands, the smoothing parameter has been given a value