CS代考 Financial Econometrics and Data Science Modelling Long-run Relationships in

Financial Econometrics and Data Science Modelling Long-run Relationships in Finance
Dr Ran Tao

7. Modelling Long-run Relationships in Finance

Copyright By PowCoder代写 加微信 powcoder

7.1 Stationarity and Unit Root Testing
7.2 Tests for Cointegration

7. Modelling Long-run Relationships in Finance 7.1 Stationarity and Unit Root Testing

7.1 Stationarity and Unit Root Testing
Stationarity and Unit Root Testing Why do we need to test for Non-Stationarity?
􏰁 The stationarity or otherwise of a series can strongly influence its behaviour and properties – e.g. persistence of shocks will be infinite for nonstationary series
􏰁 Spurious regressions. If two variables are trending over time, a regression of one on the other could have a high R2 even if the two are totally unrelated
􏰁 If the variables in the regression model are not stationary, then it can be proved that the standard assumptions for asymptotic analysis will not be valid. In other words, the usual “t-ratios” will not follow a t-distribution, so we cannot validly undertake hypothesis tests about the regression parameters.

7.1 Stationarity and Unit Root Testing
Value of R2 for 1000 Sets of Regressions of a Non-stationary Variable on another Independent Non-stationary Variable
0.00 0.25 0.50 0.75

7.1 Stationarity and Unit Root Testing
Value of t-ratio on Slope Coefficient for 1000 Sets of Regressions of a Non-stationary Variable on another Independent Non-stationary Variable
120 100 80 60 40 20 0
–250 0 t-ratio
250 500 750

7.1 Stationarity and Unit Root Testing
Two types of Non-Stationarity
􏰁 Various definitions of non-stationarity exist
􏰁 In this chapter, we are really referring to the weak form or
covariance stationarity
􏰁 There are two models which have been frequently used to characterise non-stationarity: the random walk model with drift:
yt = μ + yt−1 + ut (1) and the deterministic trend process:
yt =α+βt+ut (2) where ut is iid in both cases.

7.1 Stationarity and Unit Root Testing
Stochastic Non-Stationarity
􏰁 Note that the model (1) could be generalised to the case where yt is an explosive process:
yt =μ+φyt−1 +ut
where φ > 1.
􏰁 Typically, the explosive case is ignored and we use φ = 1 to characterise the non-stationarity because
– φ > 1 does not describe many data series in economics and finance.
– φ > 1 has an intuitively unappealing property: shocks to the system are not only persistent through time, they are propagated so that a given shock will have an increasingly large influence.

7.1 Stationarity and Unit Root Testing
Stochastic Non-stationarity: The Impact of Shocks
􏰁 To see this, consider the general case of an AR(1) with no drift:
yt = φyt−1 + ut (3) Let φ take any value for now.
􏰁 We can write:
yt−1 = φyt−2 + ut−1
yt−2 = φyt−3 + ut−2
􏰁 Substituting into (3) yields
yt = φ(φyt−2 + ut−1) + ut = φ2yt−2 + φut−1 + ut

7.1 Stationarity and Unit Root Testing (Cont’d)
􏰁 Substituting again for yt−2
yt = φ2(φyt−3 + ut−2) + φut−1 + ut
= φ3yt−3 + φ2ut−2 + φut−1 + ut 􏰁 Successive substitutions of this type lead to:
yt = φTy0 +φut−1 +φ2ut−2 +φ3ut−3 +··· +φT u0 + ut

7.1 Stationarity and Unit Root Testing
The Impact of Shocks for Stationary and Non-stationary Series
􏰁 We have 3 cases:
(1) φ<1⇒φT →0asT →∞ So the shocks to the system gradually die away. (2) φ=1⇒φT =1 ∀T So shocks persist in the system and never die away. We obtain yt = y0 + 􏰑 ut as T →∞ t=0 So the current value of y is just an infinite sum of past shocks plus some starting value of y0. (3) φ > 1. Now given shocks become more influential as time goeson,sinceifφ >1,φ3 > φ2 > φ,etc.

7.1 Stationarity and Unit Root Testing
Detrending a Stochastically Non-stationary Series
􏰁 Going back to our 2 characterisations of non-stationarity, the r.w. with drift:
yt = μ + yt−1 + ut (4) and the trend-stationary process
yt =α+βt+ut (5)
􏰁 The two will require different treatments to induce stationarity. The second case is known as deterministic non-stationarity and what is required is detrending.

7.1 Stationarity and Unit Root Testing (Cont’d)
􏰁 The first case is known as stochastic non-stationarity, where there is a stochastic trend in the data. Letting
∆yt =yt−yt−1 andLyt =yt−1 sothat
(1−L)yt =yt−Lyt =yt−yt−1. If(4)istakenandyt−1 subtracted from both sides
yt −yt−1 =μ+ut ∆ yt = μ + ut
We say that we have induced stationarity “by differencing one”.

7.1 Stationarity and Unit Root Testing
Detrending a Series: Using the Right Method
􏰁 Although trend-stationary and difference-stationary series are both “trending” over time, the correct approach needs to be used in each case.
􏰁 If we first difference the trend-stationary series, it would “remove” the non-stationarity, but at the expense on introducing an MA(1) structure into the errors.
􏰁 Conversely if we try to detrend a series which has stochastic trend, then we will not remove the non-stationarity.
􏰁 We will now concentrate on the stochastic non-stationarity model since deterministic non-stationarity does not adequately describe most series in economics or finance.

7.1 Stationarity and Unit Root Testing
Sample Plots for various Stochastic Processes: A White Noise Process
–1 –2 –3 –4
1 40 79 118 157 196 235 274 313 352 391 430 469

7.1 Stationarity and Unit Root Testing
Sample Plots for various Stochastic Processes: A Random Walk and a Random Walk with Drift
Random walk
Random walk with drift
1 19 37 55 73 91 109127145163181199217235253271289307325343361379397415433451469487

7.1 Stationarity and Unit Root Testing
Sample Plots for various Stochastic Processes: A Deterministic Trend Process
1 40 79 118 157 196 235 274 313 352 391 430 469 –5

7.1 Stationarity and Unit Root Testing
Autoregressive Processes with differing values of φ (0, 0.8, 1) 15
Phi = 1 Phi = 0.8 Phi = 0
1 53 105 157 209 261 313 365 417 469 521 573 625 677 729 784 833 885 937 989

7.1 Stationarity and Unit Root Testing
Definition of Non-Stationarity
􏰁 Consider again the simplest stochastic trend model: yt = yt−1 + ut
􏰁 We can generalise this concept to consider the case where the series contains more than one “unit root”. That is, we would need to apply the first difference operator, ∆, more than once to induce stationarity.
Definition

7.1 Stationarity and Unit Root Testing (Cont’d)
If a non-stationary series, yt must be differenced d times before it becomes stationary, then it is said to be integrated of order d. We write yt ∼ I(d). So if yt ∼ I(d) then
∆dyt ∼ I(0).
An I(0) series is stationary
An I(1) series contains one unit root
yt = yt−1 + ut

7.1 Stationarity and Unit Root Testing
Characteristics of I(0), I(1) and I(2) Series
􏰁 An I(2) series contains two unit roots and so would require differencing twice to induce stationarity.
􏰁 I(1) and I(2) series can wander a long way from their mean value and cross this mean value rarely.
􏰁 I(0) series should cross the mean frequently.
􏰁 The majority of economic and financial series contain a single unit root, although some are stationary and consumer prices have been argued to have 2 unit roots.

7.1 Stationarity and Unit Root Testing
How do we test for a unit root?
􏰁 The early and pioneering work on testing for a unit root in time series was done by Dickey and Fuller (Dickey and Fuller 1979, Fuller 1976). The basic objective of the test is to test the null hypothesis that φ =1 in:
yt = φyt−1 + ut
against the one-sided alternative φ < 1. So we have H0: series contains a unit root versus H1: series is stationary. 􏰁 We usually use the regression: ∆yt = ψyt−1 + ut so that a test of φ = 1 is equivalent to a test of ψ = 0 (since φ − 1 = ψ). 7.1 Stationarity and Unit Root Testing Different forms for the DF Test Regressions 􏰁 tests are also known as τ tests: τ, τμ, ττ. 􏰁 The null (H0) and alternative (H1) models in each case are i. H0: yt = yt−1 + ut H1:yt=φyt−1+ut, φ<1 This is a test for a random walk against a stationary autoregressive process of order one (AR(1)) ii. H0: yt = yt−1 + ut H1: yt =φyt−1 +μ+ut, φ<1 This is a test for a random walk against a stationary AR(1) with drift. iii. H0: yt = yt−1 + ut H1: yt =φyt−1 +μ+λt+ut, φ<1 This is a test for a random walk against a stationary AR(1) with drift and a time trend. 7.1 Stationarity and Unit Root Testing Computing the DF Test Statistic 􏰁 We can write where ∆yt = yt − yt−1, and the alternatives may be expressed as ∆yt =ψyt−1 +μ+λt+ut with μ = λ = 0 in case i), and λ = 0 in case ii) and ψ = φ − 1. In each case, the tests are based on the t-ratio on the yt−1 term in the estimated regression of ∆yt on yt−1, plus a constant in case ii) and a constant and trend in case iii). The test statistics are defined as 7.1 Stationarity and Unit Root Testing (Cont’d) test statistic = 􏰁 The test statistic does not follow the usual t-distribution under the null, since the null is one of non-stationarity, but rather follows a non-standard distribution. Critical values are derived from Monte Carlo experiments in, for example, Fuller (1976). Relevant examples of the distribution are shown in table 4.1 below 7.1 Stationarity and Unit Root Testing Critical Values for the DF Test Significance level CV for constant but no trend CV for constant and trend 10% −2.57 −3.12 5% −2.86 −3.41 1% −3.43 −3.96 The null hypothesis of a unit root is rejected in favour of the stationary alternative in each case if the test statistic is more negative than the critical value. 7.1 Stationarity and Unit Root Testing The Augmented (ADF) Test 􏰁 The tests above are only valid if ut is white noise. In particular, ut will be autocorrelated if there was autocorrelation in the dependent variable of the regression (∆yt) which we have not modelled. The solution is to “augment" the test using p lags of the dependent variable. The alternative model in case (i) is now written: ∆yt = ψyt−1 + 􏰑 αi∆yt−i + ut 􏰁 The same critical values from the DF tables are used as before. A problem now arises in determining the optimal number of lags of the dependent variable 􏰁 There are 2 ways – use the frequency of the data to decide – use information criteria 7.1 Stationarity and Unit Root Testing To perform an Augmented Dickey- in R (with H0: non-stationary), you can use the commands adfTest() from package fUnitRoots or stationarity.test() from package aTSA: We cannot reject the null hypothesis of non-stationarity! This is expected, as we use prices instead of price changes. 7.1 Stationarity and Unit Root Testing results with stationarity.test() from package aTSA: 7.1 Stationarity and Unit Root Testing Testing for Higher Orders of Integration 􏰁 Consider the simple regression: ∆yt = ψyt−1 + ut WetestthatH0: ψ=0vs. H1: ψ<0. 􏰁 If H0 is rejected, we simply conclude that yt does not contain a unit root. 􏰁 But what do we conclude if H0 is not rejected? The series contains a unit root, but is that it? No! What if yt ∼ I(2)? We would still not have rejected. So we now need to test H0 :yt∼I(2)vs.H1 :yt∼I(1) We would continue to test for a further unit root until we rejected H0. 7.1 Stationarity and Unit Root Testing (Cont’d) 􏰁 We now regress ∆2yt on ∆yt−1 (plus lags of ∆2yt if necessary). 􏰁 Now we test H0: ∆yt ∼ I(1) which is equivalent to H0: yt ∼ I(2). 􏰁 So in this case, if we do not reject (unlikely), we conclude that yt is at least I(2). 7.1 Stationarity and Unit Root Testing The Phillips- 􏰁 Phillips and Perron have developed a more comprehensive theory of unit root nonstationarity. The tests are similar to ADF tests, but they incorporate an automatic correction to the DF procedure to allow for autocorrelated residuals. 􏰁 The tests usually give the same conclusions as the ADF tests, and the calculation of the test statistics is complex. 7.1 Stationarity and Unit Root Testing To perform a Phillips- in R (with H0: non-stationary), you can use the command stationarity.test() from package aTSA with option method=“pp”: We still cannot reject the null hypothesis of non-stationarity. 7.1 Stationarity and Unit Root Testing Criticism of Dickey-Fuller and Phillips-Perron-type tests 􏰁 Main criticism is that the power of the tests is low if the process is stationary but with a root close to the non-stationary boundary. e.g. the tests are poor at deciding if φ=1 or φ=0.95, especially with small sample sizes. 􏰁 If the true data generating process (dgp) is yt = 0.95yt−1 + ut then the null hypothesis of a unit root should be rejected. 􏰁 One way to get around this is to use a stationarity test as well as the unit root tests we have looked at. 7.1 Stationarity and Unit Root Testing Stationarity tests 􏰁 Stationarity tests have H0: yt is stationary versus H1: yt is non-stationary So that by default under the null the data will appear stationary. 􏰁 One such stationarity test is the KPSS test (Kwaitowski, Phillips, Schmidt and Shin, 1992). 􏰁 Thus we can compare the results of these tests with the ADF/PP procedure to see if we obtain the same conclusion. 􏰁 A Comparison H0: yt ∼ I(1) H1: yt ∼ I(0) H0: yt ∼ I(0) H0: yt ∼ I(1) 7.1 Stationarity and Unit Root Testing (Cont’d) 􏰁 4 possible outcomes Reject H0 and Do not Reject H0 and Reject H0 and Do not reject H0 and Do not reject H0 Reject H0 Do not reject H0 7.2 Tests for Cointegration 7.2 Tests for : An Introduction 􏰁 In most cases, if we combine two variables which are I(1), then the combination will also be I(1) 􏰁 More generally, if we combine k I(1), 􏰁 i.e., zi,t ∼ I(1) for i = 1,2,3,...,k Then wt ∼ I(1). wt =􏰑αizi,t (6) 7.2 Tests for Cointegration Definition of Cointegration (Engle & Granger, 1987) 􏰁 However, a combination of I(1) variables might be I(0). 􏰁 Let zt be a k*1 vector of I(1) variables, then the components of zt are cointegrated if: 􏰁 There is at least one vector of coefficients α such that: α′zt = α1z1t + ... + αkzkt ∼ I(0) (7) 􏰁 Many time series are non-stationary but “move together” over time. 􏰁 If variables are cointegrated, it means that a linear combination of them will be stationary. 􏰁 There may be up to r linearly independent cointegrating relationships (where r ≤ k − 1), also known as cointegrating vectors. r is also known as the cointegrating rank of zt. 􏰁 A cointegrating relationship may also be seen as a long term relationship. 7.2 Tests for and Equilibrium 􏰁 Examples of possible Cointegrating Relationships in finance: – spot and futures prices – ratio of relative prices and an exchange rate – equity prices and dividends 􏰁 Market forces arising from no arbitrage conditions should ensure an equilibrium relationship. 􏰁 No cointegration implies that series could wander apart without bound in the long run. 7.2 Tests for Cointegration Equilibrium Correction or Error Correction Models 􏰁 When the concept of non-stationarity was first considered, a ususal response was to take the first difference of each of the I(1) variables. 􏰁 The problem with this approach is that pure first difference models have no long run solution. 􏰁 e.g. Consider yt and xt both I(1). 􏰁 The model we may want to estimate is ∆yt = β∆xt + ut (8) 􏰁 But this collapses to nothing in the long run. 􏰁 The definition of the long run that we use is where yt =yt−1 =y;xt =xt−1 =x. (9) 􏰁 Hence all the difference terms will be zero, i.e. ∆yt = 0;∆xt = 0. (10) 7.2 Tests for Cointegration Specifying an ECM 􏰁 One way to get around this problem is to use both first difference and levels terms, e.g. ∆yt = β1∆xt + β2(yt−1 − γxt−1) + ut (11) 􏰁 yt−1 − γxt−1 is known as the error correction term. 􏰁 Provided that yt and xt are cointegrated with cointegrating vector [1, −γ], then yt−1 − γxt−1 will be I(0) even though the constituents are I(1). 􏰁 We can thus validly use OLS on the above equation, if γ is known. 􏰁 The Granger representation theorem (GRT) shows that any cointegrating relationship can be expressed as an equilibrium correction model, and vice versa. 7.2 Tests for Cointegration Why is this called an Error-Correction Model? 􏰁 Expect to find β2 < 0. 􏰁 Suppose yt−1 > γxt−1. What is the effect on ∆yt 􏰁 Suppose yt−1 < γxt−1. What is the effect on ∆yt 7.2 Tests for Cointegration Testing for Cointegration in Regression 􏰁 The model for the equilibrium correction term can be generalised to include more than two variables: yt =β1 +β2x2t +β3x3t +···+βkxkt +ut (12) 􏰁 ut should be I(0) if the variables yt, x2t, . . . xkt are cointegrated 􏰁 So what we want to test is the residuals of equation (12) to see if they are non-stationary or stationary. We can use the DF/ADF test on ut. So we have the regression ∆uˆt = ψuˆt−1 + vt with vt ∼ iid. 􏰁 However, since this is a test on the residuals of an actual model, uˆt, then the critical values are changed. 7.2 Tests for Cointegration Testing for Cointegration in Regression: Conclusions 􏰁 Engle and Granger (1987) have tabulated a new set of critical values and hence the test is known as the (E.G.) test. 􏰁 What are the null and alternative hypothesis for a test on the residuals of a potentially cointegrating regression? 􏰁 What are the null and alternative hypotheses for a test on the residuals of a potentially cointegrating regression? H0 : unit root in cointegrating regression’s residuals H1 : residuals from cointegrating regression are stationary 7.2 Tests for Cointegration Methods of Parameter Estimation in Cointegrated Systems: The Engle- 􏰁 The Engle and Granger 2-Step Method 􏰁 Step 1: 1. Make sure that all the individual variables are I(1). 2. Then estimate the cointegrating regression using OLS. 3. Save the residuals of the cointegrating regression. 4. Test these residuals to ensure that they are I(0). 1. Use the Step 1 residuals to ensure: ∆yt = β0 + β1∆xt + β2uˆt−1 + wt (13) where uˆt−1 = yt−1 − γˆxt−1 7.2 Tests for Cointegration An Example of a Model for Non-stationary Variables: Lead-Lag Relationships between Spot and Futures Prices Background 􏰁 We expect changes in the spot price of a financial asset and its corresponding futures price to be perfectly contemporaneously correlated and not to be cross-autocorrelated. corr(∆ln(ft), ∆ln(st)) ≈ 1 corr(∆ln(ft), ∆ln(st−k)) ≈ 0 ∀k > 0
corr(∆ln(ft−j ), ∆ln(st)) ≈ 0 ∀j > 0
􏰁 We can test this idea by modelling the lead-lag relationship between the two.

7.2 Tests for Cointegration
Methodology
􏰁 The fair future price is given by
Ft∗ = Ste(r−d)(T −t)
where Ft∗ is the fair future price, St is the spot price, r is a continuously compounded risk-free rate of interest, d is the continuously compounded yield in terms of dividends derived from the stock index until the futures contract matures, and (T-t) is the time to maturity of the futures contract. Taking logarithms of both sides of equation above gives
ft∗ =st +(r−d)(T −t)
􏰁 First, test ft and st for nonstationarity.

7.2 Tests for Cointegration
Dickey- s on Log-Prices and Returns for High Frequency FTSE Data
Dickey-Fuller statistics for log-price data -0.1329 Dickey-Fuller statistics for returns data -84.9968
-0.7335 -114.18

7.2 Tests for Test Regression and Test on Residuals
􏰁 Conclusion: log Ft and log St are not stationary, but ∆logFt and ∆logSt are stationary.
􏰁 But a model containing only first differences has no long run relationship.
􏰁 Solution is to see if there exists a cointegrating relationship betw