the local quadratic trend model

15
Copyright © 2009 John Wiley & Sons, Ltd. The Local Quadratic Trend Model ANDREW HARVEY* Faculty of Economics and Politics, University of Cambridge, UK ABSTRACT The local quadratic trend model provides a flexible response to underlying movements in a macroeconomic time series in its estimates of level and change. If the underlying movements are thought of as a trend plus cycle, an estimate of the cycle may be obtained from the quadratic term. Estimating the cycle in this way may offer a useful alternative to other model-based methods of signal extraction, particularly when the series is short. The properties of the filter used to extract the cycle are analysed in the frequency domain and the technique is illustrated with macroeconomic time series from several countries. Copyright © 2009 John Wiley & Sons, Ltd. key words cycles; detrending; Hodrick–Prescott filter; smoothing; spectral analysis; state space; stochastic trend INTRODUCTION There are a number of reasons for wishing to model an economic time series. One is to make fore- casts. Another is to extract various components which may be of interest and to examine how they have evolved over time. Attention is often focused on ‘nowcasts’, which are estimates of components at the end of the series. For example, policy makers may want an estimate of the latest growth rate or an estimate of the probability that it is negative. Such a signal in gross domestic product (GDP) would indicate a downturn in the economy. Indeed the National Bureau of Economic Research defines a turning point in the business cycle in terms of negative growth rates. On the other hand, a turning point may be defined with respect to the growth cycle or output gap. Growth cycles are recurrent fluctuations in the series of deviations from trend. Thus growth cycle contractions include slowdowns as well as absolute declines in activity, whereas business cycle contractions include only absolute declines (recessions). The OECD cyclical indicator system uses the ‘growth cycle’ approach. An unobserved components model consisting of a stochastic trend and cycle offers a direct solu- tion to questions concerning the growth cycle. For example, when is it diminishing? when is it changing sign? Furthermore, the possibility of turning points in the business cycle can be assessed by adding estimates of the long-run growth rate to the change in the cycle. The article in Harvey et al. (2007) extends the methodology by showing how Bayesian methods can take account of parameter uncertainty in estimating components and computing probabilities of sign changes. Journal of Forecasting J. Forecast. 29, 94–108 (2010) Published online 30 December 2009 in Wiley InterScience (www.interscience.wiley.com) DOI: 10.1002/for.1144 * Correspondence to: Andrew Harvey, Faculty of Economics and Politics, University of Cambridge, Austin Robinson Build- ing, Sidgwick Avenue, Cambridge CB3 9DD, UK. E-mail: [email protected]

Upload: andrew-harvey

Post on 11-Jun-2016

217 views

Category:

Documents


3 download

TRANSCRIPT

Page 1: The local quadratic trend model

Copyright © 2009 John Wiley & Sons, Ltd.

The Local Quadratic Trend Model

ANDREW HARVEY*Faculty of Economics and Politics, University of Cambridge, UK

ABSTRACTThe local quadratic trend model provides a fl exible response to underlying movements in a macroeconomic time series in its estimates of level and change. If the underlying movements are thought of as a trend plus cycle, an estimate of the cycle may be obtained from the quadratic term. Estimating the cycle in this way may offer a useful alternative to other model-based methods of signal extraction, particularly when the series is short. The properties of the fi lter used to extract the cycle are analysed in the frequency domain and the technique is illustrated with macroeconomic time series from several countries. Copyright © 2009 John Wiley & Sons, Ltd.

key words cycles; detrending; Hodrick–Prescott fi lter; smoothing; spectral analysis; state space; stochastic trend

INTRODUCTION

There are a number of reasons for wishing to model an economic time series. One is to make fore-casts. Another is to extract various components which may be of interest and to examine how they have evolved over time. Attention is often focused on ‘nowcasts’, which are estimates of components at the end of the series. For example, policy makers may want an estimate of the latest growth rate or an estimate of the probability that it is negative. Such a signal in gross domestic product (GDP) would indicate a downturn in the economy. Indeed the National Bureau of Economic Research defi nes a turning point in the business cycle in terms of negative growth rates. On the other hand, a turning point may be defi ned with respect to the growth cycle or output gap. Growth cycles are recurrent fl uctuations in the series of deviations from trend. Thus growth cycle contractions include slowdowns as well as absolute declines in activity, whereas business cycle contractions include only absolute declines (recessions). The OECD cyclical indicator system uses the ‘growth cycle’ approach.

An unobserved components model consisting of a stochastic trend and cycle offers a direct solu-tion to questions concerning the growth cycle. For example, when is it diminishing? when is it changing sign? Furthermore, the possibility of turning points in the business cycle can be assessed by adding estimates of the long-run growth rate to the change in the cycle. The article in Harvey et al. (2007) extends the methodology by showing how Bayesian methods can take account of parameter uncertainty in estimating components and computing probabilities of sign changes.

Journal of ForecastingJ. Forecast. 29, 94–108 (2010)Published online 30 December 2009 in Wiley InterScience(www.interscience.wiley.com) DOI: 10.1002/for.1144

* Correspondence to: Andrew Harvey, Faculty of Economics and Politics, University of Cambridge, Austin Robinson Build-ing, Sidgwick Avenue, Cambridge CB3 9DD, UK. E-mail: [email protected]

Page 2: The local quadratic trend model

The Local Quadratic Trend Model 95

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

The cyclical component typically1 contains three parameters, and if these are to be sensibly esti-mated there should be enough observations to allow for several cycles. The model works well for the USA, where quarterly data are available from 1947 and there are pronounced swings in GDP. However, it becomes more diffi cult to fi t for countries with shorter time series and smaller cycles. Even in the case of the USA there are changes in the characteristics of the trend and cycle over time: in particular, there was a period of calm, known as the ‘Great Moderation’, from the mid-1980s until relatively recently. These considerations suggest the need for investigating parsimonious but fl exible models that can provide information on movements in the growth and business cycles.

The trend in a trend-cycle model normally contains a stochastic slope. When such a trend is combined with an irregular term, the result is the local linear trend model. Stochastic trends based on higher-order polynomials may also be constructed, but they are rarely used, primarily because the idea of a nonlinear forecast function is not appealing. However, there is no reason why they should not be used to provide nowcasts, and even very short-term forecasts, together with a descrip-tion of past movements in trend, cycle and growth rate. The purpose of this article is to investigate this issue. Attention is focused on the local quadratic trend (LQT) model. The properties of the esti-mator of the slope are analysed and it is shown that, somewhat surprisingly, the model is able to deliver an estimator of the growth cycle even though it contains no cyclical component.

The LQT model is described in the next section. The third and fourth sections examine the proper-ties of the extracted components using spectral analysis. This analysis explains why it is that esti-mates of the cycle can be obtained from the quadratic term in the LQT model and a comparison is made with estimates from the trend-cycle model. Spectral analysis also provides a convenient way of comparing the properties of model-based fi lters with Butterworth fi lters—a class of fi lters with the Hodrock–Prescott fi lter as a special case—and bandpass fi lters (see Gomez, 2001; Baxter and King, 1999). At the end of the fourth section, the LQT model is fi tted to macroeconomic time series for the USA, Japan and the UK, and the estimates of cycles and growth rates are compared with those obtained from trend-cycle models and the Hodrick–Prescott fi lter. The fi fth section concludes.

STOCHASTIC TREND AND CYCLE MODELS

Local linear trend modelThe simplest time series models for trend analysis are made up of a stochastic trend component, μt, and a random irregular term.

The local linear trend model—the trend component in (1) has a stochastic slope, βt, which itself follows a random walk. Thus

y t Tt t t t= + ( ) =μ ε ε σε, ~ , , , . . . ,NID 0 12 (1)

μ μ β η η σ

β β ζ ζ ση

ζ

t t t t t

t t t t

= + + ( )= + ( )− −

1 12

12

0

0

, ~ , ,

, ~ ,

NID

NID (2)

where the irregular, level and slope disturbances, εt, ηt and ζt, respectively, are mutually independent and the notation NID(0, σ 2) denotes normally and independently distributed with mean zero and

1 This is also the case if it is modelled as an AR(2) rather than a stochastic cycle.

Page 3: The local quadratic trend model

96 A. Harvey

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

variance σ 2. Setting σ 2η to zero gives an integrated random walk trend, which when estimated tends to be relatively smooth. The model is often referred to as the ‘smooth trend’ model. The signal–noise ratio, q = σ 2ζ/σ 2ε, plays the key role in determining how observations should be weighted for predic-tion and signal extraction. The higher is q, the more past observations are discounted in forecasting the future. Similarly a higher q means that the closest observations receive a higher weight when signal extraction is carried out. The Hodrick–Prescott (HP) fi lter is a special case of smoothing when, for quarterly data, q is set to 0.000625 (see Hodrick and Prescott, 1997).

Trend-cycle modelA stationary stochastic cycle, ψt, may be added to (1) to give

y t Tt t t t= + + =μ ψ ε , , . . . ,1

The trend is an integrated random walk, while the specifi cation of the cycle is

ψ

ψρ

λ λλ λ

ψ

ψ

κ

κ

t

t

c c

c c

t

t

t

*

cos sin

sin cos *

⎣⎢

⎦⎥ =

−⎡⎣⎢

⎤⎦⎥

⎣⎢

⎦⎥

1

1 tt

t T*

, , . . . ,⎡

⎣⎢

⎦⎥ = 1 (3)

where λc is a parameter in the range 0 ≤ λc ≤ π and κt and κ *t are two mutually independent Gaussian white noise disturbances with zero means and common variance σ 2κ. Given the initial conditions that the vector (ψ0, ψ*0 )′ has zero mean and covariance matrix σ 2ψ I, it can be shown that for 0 ≤ ρ < 1 the process ψt is stationary and indeterministic with zero mean, variance σ 2ψ = σ 2κ /(1 − ρ2) and τ th order autocorrelation ρτ cos λcτ . The spectrum of ψt displays a peak, centred around a frequency of λc radians, which becomes sharper as ρ moves closer to one. Higher-order cycles are discussed in Harvey et al. (2007).

Local quadratic trend modelThe local quadratic trend model is

y t Tt t t t= + ( ) =μ ε ε σε, ~ , , , . . . ,NID 0 12 (4)

with

μ μ β η

β β δ ζδ δ ζ

t t t t

t t t t

t t t

= + +

= + += +

− −

− −

1 1

1 1

1

,

*, (5)

where the vector of disturbances ηt = (ηt, ζ*t , ζt)′ is multivariate normal with zero mean and covari-ance matrix, Q.

There are a number of variants of the model:

(i) Only ζt has a positive variance, denoted σ 2ζ.(ii) The specifi cation for δ t is as in (i), but μt and βt are defi ned by a contemporaneous state model

in which βt = βt−1 + δ t and μt = μt−1 + βt. Substituting gives a lagged state model with

μ μ β δ ζt t t t t= + + +− − −1 1 1 ,

Page 4: The local quadratic trend model

The Local Quadratic Trend Model 97

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

β β δ ζt t t t= + +− −1 1

Thus Q = σ 2ζii′ in (5).(iii) The trend is the average of (i) and (ii). Thus

μ μ β δ ηt t t t t= + + +− − −1 1 10 5. (6)

with ηt = 0.5ζt, and

Q =⎡

⎢⎢⎢

⎥⎥⎥

σζ2

0 25 0 25 0 5

0 25 0 25 0 5

0 5 0 5 1

. . .

. . .

. .

The appearance of 0.5δ t−1 in the equation for the level is often the standard formulation (see Harvey, 1989, pp. 294–295).

(iv) A model derived from a continuous time formulation in which δ (t) is a Wiener process multi-plied by σ ζ (see the discussion in Harvey, 1989, pp. 483–487). The implied discrete time model has δ t−1 appearing in the level equation, as in (6), while

Q =⎡

⎢⎢⎢

⎥⎥⎥

σζ2

0 05 0 125 0 167

0 125 0 333 0 5

0 167 0 5 1 0

. . .

. . .

. . .

The smoothed trend is a quintic spline (see Kohn et al., 1992).

All the above models contain only a single parameter in addition to σ 2ε. This parameter is the signal–noise ratio, q = σ 2ζ/σ 2ε. More elaborate models may be constructed. For example, a stationary fi rst-order autoregressive component may be added to the measurement equation, (4).

The model yields estimators of the following components: the level, μt, the slope βt, and the quadratic term δ t. The slope captures movements in the ‘business cycle’, with negative values sig-nalling a turning point. Less obviously, multiplying δ t by a negative constant yields an estimator of the growth cycle or output gap. The rationale for this estimator of the cycle is the observation that in the deterministic trend-cycle model

y t t t t T( ) = + + ( ) =α β ψ , , . . . ,1

where

ψ γ λ γ λt t tc c( ) = +1 2cos sin

the second derivative of y(t) with respect to t is −λ2cψ(t), but spectral analysis is needed to understand

the stochastic case properly.

Cyclical trend modelIn the cyclical trend model, the cycle is incorporated in the equation for the level. Thus (2) is amended to

μ μ β ψ η

β β ζt t t t t

t t t

= + + += +

− − −

1 1 1

1

, (7)

Page 5: The local quadratic trend model

98 A. Harvey

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

The growth rate in the LQT model could serve as a parsimonious mechanism for tracking the business cycle, as captured by changes in the trend induced by movements in βt and ψt.

EstimationThe statistical treatment of unobserved component models is based on the state-space form (SSF). Once a model has been put in SSF, the Kalman fi lter yields estimators of the components based on current and past observations. Signal extraction refers to estimation of components based on all the information in the sample. Signal extraction is based on smoothing recursions which run backwards from the last observation. Predictions are made by extending the Kalman fi lter forward. Root mean square errors (RMSEs) can be computed for all estimators and prediction or confi dence intervals constructed.

The unknown variance parameters are estimated by constructing a likelihood function from the one-step-ahead prediction errors, or innovations, produced by the Kalman fi lter. The likelihood function is maximized by an iterative procedure. Full details can be found in Harvey (1989) and Durbin and Koopman (2001). The calculations can be done with the STAMP 8 package of Koopman et al. (2007). Once estimated, the fi t of the model can be checked using standard time series diag-nostics such as tests for residual serial correlation.

The STAMP 8 package will estimate the LQT model, (4) and (5), but with the disturbances in the trend taken to be mutually independent. The level and slope disturbances can be set to zero, enabling variant (i) of the model to be estimated. The initialization with a diffuse prior means that starting values for the level, slope and quadratic term are effectively formed from the fi rst three observations and the innovations that make up the likelihood function run from t = 4 to T.

Weights and frequency response functionsThe weights in the KF and smoother are implicit, but they may be computed as described in Koopman and Harvey (2003)—now an option in STAMP. For time-invariant models, it is often more helpful to examine and compare properties in the frequency domain. Frequency domain analysis entails taking a Fourier transform of the weights to give the frequency response function (FRF). The absolute value of the FRF is the gain. The gain can be interpreted as the effect on the spectral density of a stationary process. However, some care is needed if the information in the gain is to be used to deduce the effect of the fi lter on a nonstationary time series (see Harvey and Trimbur, 2008).

LEVEL AND SLOPE

The LQT with no disturbance on the level and slope belongs to a class of models in which the trend is defi ned such that its mth difference, Δmμt, is random. Thus it is a stochastic polynomial of order h = m − 1. The fi lter for extracting the trend in the middle of a series (the smoother) is called a Butterworth fi lter (see Gomez, 2001). The estimated trend is

�μ μt m t t

q

q Ly w L y m=

+ −= ( ) =

11 22 , , , . . .

where we follow Whittle (1983, p. 12) in adopting the convention that ⏐1 − L⏐2 = (1 − L)(1 − L−1) and q = var(Δmμt)/σ 2ε. Since wμ(L) is symmetric, the gain is the same as the FRF, that is

G w eq

qmi

mμ μλλ

λ( ) = ( ) =

+ −( )=−

2 21 22cos

, , , . . . (8)

Page 6: The local quadratic trend model

The Local Quadratic Trend Model 99

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

Figures 1 and 2 show the weights2 and gain for m = 2, 3. The weighting patterns are not dissimilar, though it can be seen that for m = 3 there is slightly less of a peak in the centre and the negative weights are more pronounced. The gain becomes sharper as m increases and, in fact, as m goes to infi nity the fi lter becomes ‘ideal’ in the sense that it is one up to a certain frequency and zero thereafter.

If λ0.5 is the frequency for which the gain equals one-half, the corresponding signal–noise ratio is

qmmλ λ λ π0 5 0 5

20 52 2 0. . .sin ,( ) = ( )[ ] < < (9)

Correspondingly, λ0.5 = 2 arcsin(qm1/(2m)/2). For m = 2, a frequency of λ0.5 = 0.1583 corresponds to

a period of 39.70 quarters or 9.93 years. Hence, with m = 2, q(λ0.5) = q(0.1583) = 0.000625 and its reciprocal is 1600, which is the HP fi lter smoothing constant for quarterly data. If the q′s are to satisfy (9) for a given λ0.5, then qm = qm

1 , m = 2, 3, . . . The q′s for the fi lters in Figures 1 and 2 obey this relationship. As can be seen, their weights have roughly the same spread and so setting the signal–noise ratio according to qm = qm

1 can be regarded as a means of equalizing the bandwidth. Since cutting out more high frequency means that the trend is smoother, the LQT trend tends to be smoother than the LLT trend for a given bandwidth.

−20 −15 −10 −5 0 5 10 15 20

0.000

0.025

0.050

0.075

0.100

0.125Weights of Level form LLT

0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0

0.25

0.50

0.75

1.00

Gain × cycle per year

Figure 1. Weights and gain for LLT trend

2 The weights for m = 1 are very different in that they are always positive and decline exponentially.

Page 7: The local quadratic trend model

100 A. Harvey

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

Since βt = μt+1 − μt, the fi lter for the slope is the same as for the level, but applied to fi rst differ-ences. Thus

�β μt t m tw L yq

q Ly m= ( ) =

+ −=+ +Δ Δ1 2 1

12 3, , , . . .

The gain with respect to fi rst differences is as in (8). If the slope is defi ned as βt = μt − μt−1 then Δyt replaces Δyt+1. Averaging the two would give (yt+1 − yt−1)/2.

Figure 3 compares the smoothed estimates of the slope from the LQT and LLT models estimated from 1986(1) to 2007(2) for US GDP. As the analysis suggests, the slope from the LQT model is slightly smoother.3

CYCLE

AnalysisTo analyse the properties of the smoothed estimator of the quadratic component in variant (i) of the LQT model, second differences are taken to give Δ2yt = δ t−2 + Δ2εt. Then the Wiener–Kolmogorov (WK) formula for extracting δ t in the middle of a doubly infi nite series is

−20 −15 −10 −5 0 5 10 15 20

0.000

0.025

0.050

0.075

0.100 Weights of Level from LQT

0.0 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1.0

0.25

0.50

0.75

1.00

Gain × cycle per year

Figure 2. Weights and gain for LQT trend

3 One reason for this is that the q estimated for the LLT leads to a smaller bandwidth, as defi ned below. If q is adjusted so that the bandwidths are equal, the LLT slope is closer to the LQT slope but still not quite as smooth.

Page 8: The local quadratic trend model

The Local Quadratic Trend Model 101

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

�δ μt t tw L yq L L

q Ly= ( )⋅ = −( )

+ −+

Δ22

2 2

6

1

1

and the associated frequency response function is

q e e

q e

i i

i

1

1

2 2

6

−( )+ −

− −

λ λ

λ (10)

The lag in yt makes no difference to the gain, which is

G Gq

qδ μλ λ λ λ

λ( ) = −( )⋅ ( ) = −( )

+ −( )2 1

2 1

8 1 3coscos

cos (11)

The gain has a maximum at a frequency of λmax = arccos(1 − (q/16)1/3). In order to take a value of unity at λmax, the gain has to be multiplied by 1.89q−1/3. Thus the estimator of the cycle is

� �ψ δt tq qLQT ( ) = − ⋅−1 89 1 3. (12)

The periods, 2π/λmax, corresponding to the maxima of the gains associated with ψ̃ tLQT(q) for q = 1, 0.1, 0.01 and 0.001 are 6.80, 10.19, 15.08 and 22.23 quarters, respectively, while the scaling

1985 1990 1995 2000 2005

−0.0025

0.0000

0.0025

0.0050

0.0075

0.0100

0.0125

GDP−Slope86 GDPSlopeLLT86

Figure 3. Smoothed slopes from LQT and LLT models

Page 9: The local quadratic trend model

102 A. Harvey

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

factors are 1.89, 4.07, 8.77 and 18.90, respectively. Figure 4 shows the gains for q = 1, 0.1 and 0.001. If the series contains a stationary component, the gain shows the effect on the frequencies of that component. The idea of multiplying by the scaling factor is to capture all the power in the sta-tionary component at the maximum frequency. When q = 0.1 is taken as an example, the maximum is at 10.9 and the gain is bigger than one-half between, roughly, 6 and 16 quarters. A bandpass fi lter, on the other hand, would have a gain of unity or zero. For example, Baxter and King (1999) recom-mend a bandpass fi lter in which the gain is one between 6 and 32 quarters (frequencies 1.05–0.20) and zero elsewhere. It is worth remarking that there is no compelling reason for such a choice of fi lter and the price paid for an ‘ideal’ fi lter—that is, one with a sharp cut-off outside a predefi ned range—is that there is a problem in fi nding suitable weights at the end of the series.

The WK fi lter for extracting the cycle in the trend-cycle model introduced above is

w Lc L s L L

c L s Lc ( ) =

−( ) ( ) + ( ){ } −+ −( ) ( ) + ( ){ }

σ ρσ σ ρ

ψ

ζ ψ

2 2 2 2 4

2 2 2 2 2

1 1

1 11 14 2 4− + −L Lσε

where

c L

L

L Ls L

L

L Lc

c

c

c

( ) = −− +

( ) =− +

1

1 2 1 22 2 2

ρ λρ λ ρ

ρ λρ λ ρ

coscos

sincos

and22

and σ 22ψ = σ 2κ/(1 − ρ2) is the variance of the cycle. The top dashed line in Figure 5 shows the gain for parameters ρ = 0.9, λc = 2π/20 (a period of 20), σ 2ψ = 500, σ 2ε = 0 and σ 2ζ = 1. The thin solid line has the same specifi cation but with σ 2ε = 500. The dashed line to the right has a period of ten. The effect of including the irregular component is to cut out some high frequency. The shape of the gain

0.0 0.2 0.4 0.6 0.8 1.0 1.2 1.4 1.6 1.8 2.00.0

0.2

0.4

0.6

0.8

1.0

Lambda

Gain

Figure 4. Standardized gains for q = 1 (thick line), q = 0.1 (dashes) and q = 0.001

Page 10: The local quadratic trend model

The Local Quadratic Trend Model 103

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

for the cycle with period ten is not dissimilar from that of the solid line showing the gain for ψ̃ tLQT(q) with q = 0.1. In all cases the gain of zero at the origin suggests that there will be little spillover from a stochastic trend.

From (10), the phase shift for δ ̃t, in time units, is

1 2 2

1 2 21

λλ λλ λ

arctansin sincos cos

− +− +

=

For variant (ii) of the model, the phase shift is minus one. Averaging gives no phase shift and the fi lter can be expressed as

�δ μ μt t t t t t t tw L y y w L y y y y y= ( ) +( ) = ( ) − + − +( )+ + + + −Δ Δ2

22

2 1 1 22 2 2 2 2

The gain, Gδ (λ), is pre-multiplied by [(2 + 2 cos 2λ)1/2/2], but this makes very little difference to its shape.

IllustrationsFitting the LQT model to (the log of) quarterly US investment from 1986(1) to 2007(2) gives q̃ = 0.072. The estimated period in a trend-cycle model is 24 quarters. Some plots are shown in Figures 6–8. Since the cycle is very clear, there is no diffi culty in fi tting a trend-cycle model, even though the sample is relatively short. A comparison of the cycles obtained from the two models in Figure 8 shows that the movements are similar, but the movements in the LQT cycle have a somewhat smaller amplitude.

0.0 0.2 0.4 0.6 0.8 1.0 1.2 1.40.0

0.1

0.2

0.3

0.4

0.5

0.6

0.7

0.8

0.9

1.0

Lambda

Gain

Figure 5. Gains for (a) trend-cycle model with (i) period of 20 and no irregular (top thin dashed line), (ii) period of 20 and irregular (thin line), (iii) period of 10 and irregular (dashed line) and (b) LQT cycle with q = 0.1 (thick central line)

Page 11: The local quadratic trend model

104 A. Harvey

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

1985 1990 1995 2000 2005

6.75

7.00

7.25

7.50INV Level

1985 1990 1995 2000 2005

−0.02

0.00

0.02

INV−Slope

Figure 6. Trend and slope from LQT model fi tted to US investment

Unlike the USA, Japan has very few clearly defi ned growth cycles. Thus fi tting a trend-cycle model is not easy and possibly not appropriate. Figure 9 shows the cycle from the LQT model fi tted to (the log of ) quarterly Japanese US GDP per capita from 1961(1) to 2000(2). The signal–noise ratio was estimated as q̃ = 0.105 and the movements in the LQT cycle seem quite plausible. Note that a signal–noise ratio of 0.1 implies that the gain of the cycle fi lter is at its maximum at around ten quarters and that the scaling factor in (12) is approximately four.

Finally, Figure 10 shows the cycle from the LQT model fi tted to (the log of) quarterly UK GDP together with cycles obtained as deviations from the HP fi lter. The signal–noise ratio was close to 0.1, as for Japan. The sample is only from 1986 and so the trend-cycle model is again not easy to fi t. In the fi rst part of the sample the LQT cycle is much closer to the HP fi lter, with a smoothing constant of 160 rather than the standard 1600, but after 1994 there is little difference. Note that the LQT cycle is smoother than the HP cycles because, as is clear from Figure 5, high-frequency move-ments are cut out.

CONCLUSION

The LQT model is parsimonious and provides a simple way for extracting estimates of the growth cycle (from the quadratic term) and the business cycle (from the growth term). Filtered estimates of

Page 12: The local quadratic trend model

The Local Quadratic Trend Model 105

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

1985 1990 1995 2000 2005

6.75

7.00

7.25

7.50INV Level

1985 1990 1995 2000 2005

−0.10

−0.05

0.00

0.05

INV−Cycle

Figure 7. Trend and cycle from trend-cycle model fi tted to US investment

1985 1990 1995 2000 2005

−0.075

−0.050

−0.025

0.000

0.025

0.050

0.075 LQTcycle log_INV−Cycle

Figure 8. LQT cycle and cycle from trend-cycle model for US investment

Page 13: The local quadratic trend model

106 A. Harvey

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

1960 1965 1970 1975 1980 1985 1990 1995 2000

9.0

9.5

10.0LJap

1960 1965 1970 1975 1980 1985 1990 1995 2000

−0.01

0.00

0.01

0.02

0.03DLJapSlope−4

Figure 9. Cycle from the LQT model for Japanese per capita GDP

growth rates and cycles provide information on turning points (which may be defi ned with respect to growth or business cycles), though more reliable estimates are obtained by smoothing after a few periods have passed.

Spectral analysis is illuminating in showing why it is that useful estimates of the growth cycle can be obtained from the LQT model. In particular, the gain is quite close to that of the gain for extracting a cycle from a model made up of trend, cycle and irregular components. Applying the technique to real data indicates that, while the main upturns and downturns occur at the right time, the larger deviations from trend tend to be underestimated.

ACKNOWLEDGEMENTS

Earlier versions of this paper were presented at the 5th Colloquium on Modern Tools for Business Cycle Analysis at Eurostat and at the Cambridge workshop on Unobserved Components in June 2008. Financial support from the ESRC under the grant Time-Varying Quantiles, RES-062-23-0129, is gratefully acknowledged.

Page 14: The local quadratic trend model

The Local Quadratic Trend Model 107

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

1985 1990 1995 2000 2005

−0.02

−0.01

0.00

0.01

0.02

SlopeCy86−7 HPLGDP160

HPLGDP

Figure 10. UK GDP cycles from LQT model and HP fi lters

REFERENCES

Baxter M, King RG. 1999. Measuring business cycles: approximate band-pass fi lters for economic time series. Review of Economics and Statistics 81: 575–593.

Durbin J, Koopman SJ. 2001. Time Series Analysis by State Space Methods. Oxford University Press: Oxford.Gomez V. 2001. The use of Butterworth fi lters for trend and cycle estimation in economic time series. Journal of

Business and Economic Statistics 19: 365–373.Harvey AC. 1989. Forecasting, Structural Time Series Models and the Kalman Filter. Cambridge University

Press: Cambridge, UK.Harvey AC, Trimbur T. 2008. Trend Estimation and the Hodrick–Prescott Filter. Journal of the Japanese Statisti-

cal Society (volume in honor of H. Akaike) 38: 41–49.Harvey AC, Trimbur T, van Dijk H. 2007. Trends and cycles in economic time series: a Bayesian approach.

Journal of Econometrics 140: 618–649.Hodrick RJ, Prescott EC. 1997. Postwar US business cycles: an empirical investigation. Journal of Money, Credit

and Banking 24: 1–16.Kohn R, Ansley CF, Wong C-H. 1992. Nonparametric spline regression with autoregressive moving average

errors. Biometrika 79: 335–346.Koopman SJ, Harvey AC. 2003. Computing observation weights for signal extraction and fi ltering. Journal of

Economic Dynamics and Control 27: 1317–1333.Koopman SJ, Harvey AC, Doornik JA, Shephard N. 2007. STAMP 8: Structural Time Series Analysis Modeller

and Predictor. Timberlake Consultants: London.Whittle P. 1983. Prediction and Regulation (2nd edn). Blackwell: Oxford.

Page 15: The local quadratic trend model

108 A. Harvey

Copyright © 2009 John Wiley & Sons, Ltd. J. Forecast. 29, 94–108 (2010) DOI: 10.1002/for

Author’s biography:Andrew Harvey is Professor of Econometrics at Cambridge University, having previously been Professor of Econometrics at the London School of Economics. He has held visiting positions at the University of British Columbia and the University of California at Berkeley. He has published widely in statistics, econometrics, fi nance and operations research and is on the editorial board of the Journal of Time Series Analysis. He is the author of well-known textbooks in econometrics and time series analysis and has written a monograph: Forecasting, Structural Time Series Models and the Kalman Filter.

Author’s address:Andrew Harvey, Faculty of Economics and Politics, University of Cambridge, Austin Robinson Building, Sidgwick Avenue, Cambridge CB3 9DD, UK.