ading and Investment
with cn = 1. A rejection of this hypothesis can be taken as evidence that term premiumsvary with time, i.e., that the expectations theory does not hold.It can be shown that the theoretical values of cn implied by the two-factor modelcorrespond to:cn =
(B1 + Bn − Bn+1 )T 0 (B1 − T (Bn − Bn−1 ))(B1 + Bn − Bn+1 )T 0 (B1 + Bn − Bn+1 )
(3.35)
In the general case:lim cn =
n→∞
B1T 0 B1=1B1T 0 B1
as Bn−1 = Bn = Bn+1
when n → ∞
3.5 IDENTIFICATIONContrary to the pioneer interest rate models, such as Cox et al. (1985a), where the shortterm interest rate inﬂuenced the whole term structure, the latent factor models do notuse explicit determinants of the yield curve. Therefore, as referred to in Backus et al.(1997), the major outstanding issue in this context is the economic interpretation of theinterest rate behaviour approximated with afﬁne models, in terms of its monetary andreal economic factors. Our conjecture is that two factors seem to drive the German termstructure of interest rates: one factor related to the ex-ante real interest rate and a secondfactor linked to inﬂation expectations.As previously stated, the identiﬁcation will thus be assessed in three different ways, theﬁrst being based on the model developed in Fung et al. (1999). As it is supposed that oneof the latent factors is related to inﬂation, one factor is identiﬁed with that variable, whichis assumed to be an AR(1) process. The inﬂation, denoted by πt , will thus be deﬁned as:22(πt+1 − π) = ρ(πt − π) + ut+1
(3.36)
where π is the unconditional mean of the inﬂation rate and ρ is a parameter that measuresthe rate of mean reversion. Considering that the short-term interest rate is a risk-free rate,as there are no expectation revisions in a one-period investment, the hypothesis is thatit is the sum of the short-term real interest rate (r1,t ) with the one-period inﬂation rateexpectation:y1,t − δ = (r1,t − r) + Et (πt+1 − π)(3.37)where the long-run mean of the short-term interest rate is equal to the sum of the unconditional means of the real interest rate and the inﬂation rate (δ = r + π). The componentof the short-term rate related to the second factor may be considered as the one-periodinﬂation expectation:s2,t = Et (πt+1 − π) = ρ(πt − π) = ρ π̃t
(3.38)
where π̃t denotes deviation of inﬂation from the steady-state value.22Inﬂation is measured as the annual change in the log CPI. This measure is preferred because the quarteron-quarter annualised change in the log CPI is extremely volatile, often with negative readings. Our measureshould be interpreted as capturing the underlying or smoothed one-period inﬂation rate. Inﬂation is measuredas year-on-year changes in the CPI in deviations from its mean, due to the deﬁnition of the factors as havingzero mean.
Modelling the Term Structure of Interest Rates
85
From equations (3.36) and (3.38) the value of the second factor in t + 1 is:s2,t+1 = Et+1 (π̃t+2 ) = ρ π̃t+1 = ρ(ρ π̃t + ut+1 ) = ρs2,t + ρut+1
(3.39)
Comparing equations (3.22) and (3.39), we have the following identiﬁcation betweenthe parameters of the second factor and the inﬂation process:ρ = ϕ2ρut+1 = σ2 ε2,t+1
(3.40)
Using equations (3.38) to (3.40), the following relationship between the inﬂation andthe second factor is obtained:1π̃t = s2,t(3.41)ϕ2An advantage of this identiﬁcation procedure is that ex-ante real interest rates canbe derived. The major drawback of this technique is that it implies the second factorto explain simultaneously the inﬂation as well as the long-term rates, which in someperiods may evidence signiﬁcantly different volatilities. Consequently, during the periodsof higher volatility of the long-term rates, the estimated inﬂation tends to present a moreirregular behaviour than the true inﬂation.Secondly, the procedure sketched above is based on the assumption in equation (3.36),which is not necessarily the optimal model for forecasting inﬂation. In fact, this model istoo simple concerning its lag structure and also does not allow for the inclusion of othermacroeconomic information that market participants may use to form their expectationsof inﬂation. For example, information about developments in monetary aggregates, commodity prices, exchange rates, wages and unit labour costs, etc., may be used by marketparticipants to forecast inﬂation and, thus, may be reﬂected in the bond pricing process.However, a more complex model would certainly not allow a simple identiﬁcation of thefactor.One way to overcome these problems is by using a joint model for the term structureand the inﬂation, where the latter still shares a common factor with the interest rates butis also determined by a second speciﬁc factor.23 Thus, inﬂation can be modelled as afunction of two factors:1πt = (Aπ + BπT sπ,t )(3.42)nwhere πt = (2t , s1π,t )T ands1π,t+1 = ϕ1π s1π,t + σ1π ε1π,t+1
(3.43)
Comparing to the model developed in Fung et al. (1999), this model offers the advantage of not restricting the factor loadings to the values of the parameters of the termstructure loadings, as well as providing an additional factor to explain the inﬂation moves.23In this case, the loading of the second factor in the inﬂation equation is independent from the loading in termstructure equations, as no explicit relationship is assumed between the yields and the inﬂation and, consequently,there are no recursive restrictions between the yields and the inﬂation.
86
Applied Quantitative Methods for Trading and Investment
Therefore, the second term structure factor does not have to be liable simultaneously forthe long-term interest rates and the inﬂation, avoiding more volatile estimates for theinﬂation in periods of higher volatility of the long-term rates.In order to overcome the problems detected in the ﬁrst identiﬁcation model, the leadingindicator properties of s2,t for inﬂation were also analysed, by setting up a VaR modelwith p lags:24xt = A1 xt−1 + · · · + Ap xt−p + µ + ut(3.44)where xt is (2 × 1) and each of the Ai is a (2 × 2) matrix of parameters with genericielement denoted by [ak,j] and ut ∼ IN(0, ). The vector xt is deﬁned as xt = (πt , s2,t )T .Testing whether s2,t has leading indicator properties for inﬂation corresponds to testingp1= · · · = a1,2 = 0. This is a test for Granger causality, i.e., a testthe hypothesis H0 : a1,2of whether past values of the factor along with past values of inﬂation better “explain”inﬂation than past values of inﬂation alone. This of course does not imply that bond yieldscause inﬂation. Instead it means that s2,t is possibly reﬂecting bond market’s expectationsas to where inﬂation might be headed.In assessing the leading indicator properties of s2,t , the Granger causality test can besupplemented with an impulse-response analysis. The vector MA(∞) representation ofthe VaR is given by:xt = µ + ut + 1 ut−1 + 2 ut−2 + · · ·
(3.45)
The matrix z will then correspond to:∂xt+z= z∂ut
(3.46)
that is, the row i, column j element of z identiﬁes the consequences of a one-unitincrease in the j th variable’s innovation at date t (uj,t ) for the value of the ith variableat time t + z(xi,t+z ), holding all other innovations at all dates constant.A plot of the row i, column j element of z (∂xi,t+z /∂uj,t ), as a function of z is theimpulse-response function. It describes the response of (xi,t+z ) to a one-time impulse inxj,t , with all other variables dated t or earlier held constant. Supposing that the date tvalue of the ﬁrst variable in the autoregression s2,t is higher than expected, so that u1,t ispositive, then we have:25∂ Ê(xi,t+z |s2,t , xt+1, xt+2, . . . , xt−p)
∂s2,t
=
∂xi,t+z∂u1,t
(3.47)
Thus if s2,t is a leading indicator of inﬂation, a revision in market expectations of, xt−2, . . . , xt−p) should be captured by the marginal impactinﬂation ∂ Ê(xi,t+z |s2,t , xt−1of a shock to the innovation process in the equation for s2,t .24
See, e.g., Hamilton (1994), chap. 11.We use a Cholesky decomposition of the variance–covariance of the innovations to identify the shocks. Weorder inﬂation ﬁrst in the VaR to reﬂect the idea that whereas inﬂation does not respond, contemporaneously,to shocks to expectations, these may be affected by contemporaneous information on inﬂation.25
Modelling the Term Structure of Interest Rates
87
3.6 ECONOMETRIC METHODOLOGY AND APPLICATIONSAs the factors that determine the dynamics of the yield curve are non-observable andthe parameters are unknown, a Kalman ﬁlter and a maximum likelihood procedure werechosen for the estimation of the model.26 In a brief description, the Kalman ﬁlter is analgorithm that computes the optimal estimate for the state variables at a moment t usingthe information available up to t − 1.The starting point for the derivation of the Kalman ﬁlter is to write the model instate-space form, which includes an observation or measurement equation and a state ortransition equation, respectively:Yt = A · Xt + H · St + wt(r×n) (n×1) (r×k) (k×1)(r×1)(r×1)
(3.48)
St = C + F · St−1 + G · vt(k×k) (k×1)(k×1)(k×k) (k×1)(k×1)
(3.49)
where r is the number of variables to estimate, n is the number of observable exogenousvariables, k is the number of non-observable or latent exogenous variables (the factors),and wt and vt are i.i.d. residuals, distributed as wt ∼ N (0, R) and vt ∼ N (0, Q).The variance matrices are written as:R = E(wt wt )
(3.50)
)Q = E(vt+1 vt+1
(3.51)
(r×r)
(k×k)
As previously mentioned, two non-identiﬁed models were estimated, with two and threefactors, and using two different databases in the former case. Considering the shorterdatabase, the two-factor model was estimated using the ﬁles on the CD-Rom “va2fgrse”and “v2mlgrse”, containing respectively the Kalman ﬁlter and the maximum likelihoodprocedure, written in Matlab code. Conversely, for the three-factor model the ﬁles usedwere “va3fgrse” and “v3mlgrse”. The longer database was used only to estimate thetwo-factor models, by the ﬁles “va2fgrsb” and “v2mlgrsb”.Though there are some packages containing automatic procedures to run the Kalmanﬁlter (namely TSP), Matlab gives the chance to easily get, from the same ﬁle, the econometric results and the yield, forward, volatility and term premium curves, while imposingthe required restrictions on the parameters.According to equation (3.13), the measurement or observation equation in our two- andthree-factor non-identiﬁed models may be written as:  b1,1 b2,1 · · · bk,1y1,ta1,tw1,ts 1,t. y2,t   a2,t   w2,t    b1,2 b2,2 .. bk,2 ..  + k = 2 or 3 . = . + . ...... ..   ..  ...... .  ..sk,tyl,tal,twl,tb1,l b2,l · · · bk,l(3.52)26The maximum likelihood procedure is usually adopted when the parameters are unknown. Routines areprovided for these algorithms.
88
Applied Quantitative Methods for Trading and Investment
where y1,t , y2,t , . . . , yl,t are the l zero-coupon yields at time t with maturities j = 1, 2, . . . , uperiods and w1,t , w2,t , . . . , wl,t are the normally distributed i.i.d. errors, with null mean andstandard deviation equal to ej2 , of the measurement equation for each interest rate considered,aj = Aj /j , bk,j = Bk,j /j .27Following equation (3.22), the transition or state equation is: ϕ1s1,t+1 .   ..  =  00sk,t+1
0...0

 s1,tσ1 .  0   ..  +  0ϕk0sk,t0
0..
.0

v1,t+1 . 0   .. σkvk,t+10
(3.53)
v1,t+1 , . . . , vk,t+1 being orthogonal shocks with null mean and variances equal to σ12 , . . . , σk2 ,respectively. As in the estimation of the models, the information on the homoskedasticityof yields is also exploited. The observation equation may be rewritten as follows: b 1,1a1,ty1,ty2,tb1,2  a2,t    ..  .....  .    .  al,t  yl,t +  b1,l= Vart (y1,t+1 )   al+1,t   0 Vart (y2,t+1 )   al+2,t  0  .  ...  .   ....Vart (yl,t+1 )a2l0
· · · bk,1υ1,t.. υ2,t . bk,2 ..  .. ... . .  s1,tυl,t · · · bk,l   ...  + υl+1,t 00  sk,tυ00  l+2,t .....  .. .. υ2l,t00
(3.54)
22where al+j,t = (B1,jσ12 + B2,jσ22 )/n2 and 2l is the number of variables to estimate (r inequation (3.48)). In this way we adjust simultaneously the yield curve and the volatilitycurve, avoiding implausible estimates for the latter, generated by parameters that assureadequate estimations for the yields.Regarding equations (3.48) and (3.49), in this model A is a column vector with elements22aj,t for the ﬁrst l rows (l = 9) and (B1,jσ12 + B2,jσ22 )/n2 for the next l rows; Xt is a2l-dimension column vector of one’s (r = 1), C is a column vector of zeros and F is ak × k diagonal matrix, with typical element Fi,i = ϕi .In all these cases, the starting values for the parameters were computed as those minimising the squared sum of residuals between the estimated yields (with the factors beingzero) and the mean observed yields.28When the link between the second factor and the inﬂation is considered in line with(3.41), the observation equation becomes:29
27Therefore, the parameter l in the state-space model is equal to 9 and there are 18 equations in the measurementequation of the model. Besides the recursive restrictions, the parameters were estimated subject to the usualsignal restrictions.28This minimisation was performed using the Excel Solver add-in.29In this case, only the two-factor model is ﬁtted.
Modelling the Term Structure of Interest Rates




89

b1,1a1,ty1,tyab2,t  2,t   1,2  .   ...  ..   ...    al,t   b1,lyl,t   Vart (y1,t+1 )  =  al+1,t  +  0   Vart (y2,t+1 )   al+2,t   0    .   ....  ..  .   . Vart (yl,t+1 )   a2l   0π̃t00

b2,1b2,2 .. . b2,l  s1,t0  s2,t0 .. . 0 bπ


υ1,t υ2,t  .  ..  υl,t + υl+1,t  υl+2,t  .  ..  υ2l,t υπ
(3.55)
This model is estimated with the ﬁles “va2fgrin” and “v2mlgrin” on the CD-Rom,containing respectively the Kalman ﬁlter and the maximum likelihood procedure, alsowritten in Matlab code. Conversely, when the inﬂation is modelled as motivated by twofactors, as in (3.42), the observation equation is:  a1,tb1,1y1,t  a2,t   b1,2y2,t    ..   ...  ....   ayl,t  l,t   b1,l Vart (y1,t+1 )  =  al+1,t  +  0   Vart (y2,t+1 )   al+2,t   0    ..   ...  .   ...   Vart (yl,t+1 )   a2l   00π̃t0
b2,1b2,2...b2,l00...0b2π
υ1,t0 υ2,t 0  . .. ..   . 0  s1,t υl,t 0  s2,t +  υl+1,t  υl+2,t 0  s1π,t . ..  .. .  υ2l,t 0 b1πυπ
In this case, the transition equation becomes:  s1,t+1ϕ1 0s1,tσ10 s2,t+1  =  0 ϕ20   s2,t  +  00 0 ϕ1π0s1π,t+1s1π,t
0σ20
ε1,t+100   ε2,t+1 σ1πε1π,t+1
(3.56)
(3.57)
The routines for this model are not included, given that they are very similar to theprevious ones. For instance, the model in equations (3.56) and (3.57) is similar to the onein equations (3.53) and (3.54), adding to this an observation equation for the variable π̃tor its determining factor.All the Matlab routines used have a similar structure: after the introductory comments,a set of general procedures is deﬁned. These start with the deﬁnition of the log-likelihoodfunction, followed by the loading of the sample data. Afterwards, the original parametersand the matrices are deﬁned, as well as some self-explanatory procedures. The followingblock of the routine is focused on the deﬁnition of the transformed parameters. Theseare created in the next block of the routine (“Deﬁning the Original Parameters”), inorder to allow us to deﬁne the original parameters as functions of the former, imposingconstraints on the original parameter values such as the mean-reversion coefﬁcients ofthe factors (ϕi ) to be between zero and one, the volatilities of the factors (σi ) and thevariances of the errors in the observation errors to be positive and one of the market
90
Applied Quantitative Methods for Trading and Investment
prices of risk to be negative,30 so as to impose the risk-premium curve to be mostlypositive. In this block, the starting values of the factors for the Kalman ﬁlter are alsosettled to zero.The matrices containing several factor loadings for the different maturities in equations(3.24) and (3.25) are deﬁned next, as well as the recursive restrictions on those factorloadings. In the routine block entitled “Deﬁning the matrices for the estimation”, all thematrices to write the Kalman ﬁlter in the state-space form are settled. We start by computing the factor loadings for the maturities considered in the sample.31 Then the columnvector A is formed, with rows 10 to 18 containing the volatilities as in equation (3.29).32The 19th row is zero, as the inﬂation only depends on the second factor and does nothave an independent term. The matrix H , containing the factor loadings in the observation equations, is formed next. Given that the volatilities are constant, rows 10 to 18 arenull. The 19th row contains the link between the inﬂation and the second factor, as inequation (3.41).Subsequently, the matrix F containing the mean-reversion parameters of the factorsis formed. As the factors are assumed to be independent, only the elements in the maindiagonal are non-zero. After creating the matrices with the variances of the errors ofthe observation and the state equations, the volatility and the term premium curves arecomputed for the maturities considered in the sample.The estimation of the Kalman ﬁlter is performed afterwards. It departs from assumingthat the starting value of the state vector S is obtained from a normal distribution withmean Ŝ0 and variance P0 . Ŝ0 can be seen as a guess concerning the value of S using allinformation available up to and including t = 0. As the residuals are orthogonal to thestate variables, Ŝ0 cannot be obtained using the data and the model. P0 is the uncertaintyabout the prior on the values of the state variables.The next step is to obtain a ﬁrst estimate for the mean and the variance of the statevariables. Concerning the former, from Ŝ0 and equation (3.49), the optimal estimator forS1 will be:Ŝ1|0 = C + F Ŝ0(3.58)Conversely, the variance–covariance matrix will be updated as follows:P1|0 = E[(S1 − Ŝ1|0 )(S1 − Ŝ1|0 ) ]= E[(C + F S0 + Gv1 − C − F S0 )(C + F S0 + Gv1 − C − F S0 ) ]= E[(F v0 + Gv1 )(v0 F  + v1 G )]= E(F v0 v0 F  ) + E(Gv1 v1 G )= FP1|0 F  + GQ1 G
(3.59)
Given that vec(ABC) = (C  ⊗ A) · vec(B), P1|0 may be obtained from:3330
In this case, we opted for the second factor.The element in brackets is the column number in the matrices A and H of the observation equations, whichcorresponds to the maturity in months added by one, given that the ﬁrst column of each of those matrices isthe initial factor loadings (a0 and bk,0 ).32The expression in equation (3.29) is multiplied by 1200 in order to annualise the yields and express them aspercentages.33In the Matlab routines, we start by updating the variance–covariance matrix in the vector form.31
Modelling the Term Structure of Interest Rates
91
vec(P1|0 ) = vec(FP1|0 F  ) + vec(GQ1 G )= (F ⊗ F ) · vec(P1|0 ) + (G ⊗ G) · vec(Q1 )−1=[(G ⊗ G) · vec(Q1 )]I −(F ⊗ F )(r 2 ×r 2 )
(3.60)
This block of the routine is concluded by assuming that the starting value of the loglikelihood function is zero. The following block, entitled “Derivation of the KF”, starts bythe estimation of the independent variables, based on the assumption that wt is independentfrom Xt and from all prior information on y and x (denoted by ζt−1 ). Therefore, theforecast of yt conditional on Xt and ζt−1 can be obtained directly from (3.48):E(yt |Xt , ζt−1 ) = AXt + H Ŝt|t−1
(3.61)
The several estimates from equation (3.61) are stored in a matrix deﬁned as YE in theroutines, where the number of rows corresponds to the number of observation equationsand the number of columns is the number of observations added by one. Given that w