exploring granger causality for time series via wald test...

25
Exploring Granger Causality for Time series via Wald Test on Estimated Models with Guaranteed Stability Nuntanut Raksasri Jitkomut Songsiri Department of Electrical Engineering, Faculty of Engineering, Chulalongkorn University Nov 3, 2016 1 / 25

Upload: others

Post on 24-Sep-2020

8 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Exploring Granger Causality for Time series via WaldTest on Estimated Models with Guaranteed Stability

Nuntanut RaksasriJitkomut Songsiri

Department of Electrical Engineering, Faculty of Engineering,Chulalongkorn University

Nov 3, 2016

1 / 25

Page 2: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

OUTLINE

Introduction and Objective

Granger causality

Statistical test for Granger causality Analysis

Stability Conditions

Result and Conclusion

2 / 25

Page 3: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Introduction and Objective

By knowing the relationship of the parameters in time series data, we canexplain the dynamic of the time series data.

explain relationship between the time series data by using the Grangercausality concept and autoregressive model.

estimate stable model with Granger causality constraints.

3 / 25

Page 4: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Flow Chart of the Paper

ML estimation of AR model

with closed-form solution

Wald test

on 𝐴

Estimation of AR Subject to

Granger causality condition

Estimation of AR Subject to Granger

causality condition + Stability condition

Is the model stable?

Time Series Data

𝐴, Σ Zero pattern of 𝐴

AR model with Granger causality

yes

noStable AR modelwith Granger causality

Sparsity pattern of 𝐴 Sparsity pattern of 𝐴

Some eigenvalues of 𝒜lie outside the unit circle

All eigenvalues of 𝒜lie on the unite circle Sparsity pattern of 𝐴

v

Learn relationship

v

model stability

4 / 25

Page 5: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Auto-Regressive (AR) Model

Time series data can be represented by an AR model,

y(t) = c + A1y(t − 1) + A2y(t − 2) + ...+ Apy(t − p) + v(t) (1)

y(t) = (y1(t), y2(t), ..., yn(t)) ∈ Rn

A1,A2, ...,Ap ∈ Rnxn are AR coefficients (p is lag order of the model)

c ∈ Rn is a constant vector

v(t) is a Gaussian noise process with variance Σ

the observations y(1), y(2), ..., y(N) are available.

y(1), y(2), ..., y(p) are deterministic values and given.

5 / 25

Page 6: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Granger causality

“Granger causality” is a term for a specific notion of causality intime-series analysis. The idea of Granger causality is a simple one:

XG−causes−−−−−−→ Y

A variable X “Granger-causes” Y if Y can be better predicted usingthe histories of both X and Y than it can using the history of onlyY .

6 / 25

Page 7: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Granger Causality

Apply the concept of Granger causality to AR model in equation (1)

the causality of the model can be written in linear equation form that is ifyj “not Granger-cause” to yi then

(Ak)ij = 0, k = 1, 2, .., p

where (Ak)ij denotes the (i , j) entry of Ak .

Granger Causality structure can be read from the zero pattern ofestimated AR coefficient matrix.

7 / 25

Page 8: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

example

Consider AR(4) (AR model when p=4) and y(t) ∈ R3,if y2 “not Granger-cause” to y1 then the model could bey1(t)y2(t)y3(t)

= c +

X 0 XX X XX X X

y1(t − 1)y2(t − 1)y3(t − 1)

+

X 0 XX X XX X X

y1(t − 2)y2(t − 2)y3(t − 2)

+

X 0 XX X XX X X

y1(t − 3)y2(t − 3)y3(t − 3)

+

X 0 XX X XX X X

y1(t − 4)y2(t − 4)y3(t − 4)

+ v(t)

8 / 25

Page 9: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Maximum likelihood estimation

To estimate A and Σ by using maximum likelihood estimation, we solvingthe problem

maximizeA,Σ

N − p

2log det Σ−1 − 1

2‖L(Y − AH)‖2

F (2)

when LTL = Σ−1 and the problem is equivalent to the least-squaresproblem

minimizeA

‖Y − AH‖2F (3)

where

Y =[y(p + 1) y(p + 2) · · · y(N)

]n×(N−p)

,

H =

1 1 · · · 1

y(p) y(p + 1) · · · y(N − 1)y(p − 1) y(p) · · · y(N − 2)

......

...y(1) y(2) · · · y(N − p)

(np+1)×(N−p)

9 / 25

Page 10: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Statistical test for Granger causality Analysis

The null hypothesis for Granger causality condition will be

H0 : (Ak)ij = 0 for k = 1, 2, . . . , p

and the Wald test is based on the following test statistic:

Wij = BTij

[Avar(θ)ij

]−1Bij

where Bij =(

(A1)ij , (A2)ij , . . . , (Ap)ij

), θ is the vectorization of A, and

Avar(θ)ij is the main diagonal block of a consistent estimate of the

asymptotic covariance matrix of θ.

10 / 25

Page 11: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Statistical test for Granger causality Analysis

X 3.2486 35.0241 0.1986 11.5292

0.1279 X 153.831 35.5729 3.2287

13.4569 0.608 X 15.0093 2.1324

12.3471 21.6202 30.7289 X 2.2625

43.4160 2.3035 2.2536 1.5259 X

X 0 X 0 X

0 X X X 0

X 0 X X 0

X X X X 0

X 0 0 0 X

C = 9.4877 when 𝛼 = 0.05 and 𝑝 = 3

If 𝑊𝑖𝑗 > C Non Zero

Zeros Structure

IDEA : if 𝐻0is true, ( 𝐴𝑘)𝑖𝑗should equal to 0

In Wald test, 𝐻0 is reject if W > C

where C = 𝐹−1(1 − 𝛼) is critical valueand 𝛼 = Prob(𝑊 > 𝐶) is the significance level.

( 𝐴𝑘)12

W

Under the null hypothesis that (Ak)ij = 0, the Wald statistic W convergesin distribution to Chi-square distribution with p degrees of freedom.

11 / 25

Page 12: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Wald test Results

By generating y(t) = AH(t) + v(t) and the model parameter Ak aregenerated by choosing some element to be equal to zero.

(a) α = 0.01 (b) α = 0.1

� is intersect between non-zeros components© is true component is zero but the estimated is non-zero+ is true component is non-zero but the estimated is zeroand blank is intersect between zero components 12 / 25

Page 13: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

AR estimation with Granger causality constraints

After knowing the Granger causality pattern, we solve this optimizationproblem to estimate A with Granger causality condition.

minimizeA

‖Y − AH‖2F

subject to (Ak)ij = 0

The estimated model parameter is not guarantee to be stable

we need a stability condition.

13 / 25

Page 14: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Stability Condition

we can write the AR model in discrete-time linear system

y(t)

y(t − 1)...

y(t − p + 1)

=

A1 A2 . . . Ap−1 Ap

I 0 . . . 0 00 I . . . 0 0...

.... . .

......

0 0 . . . I 0

︸ ︷︷ ︸

A

y(t − 1)y(t − 2)

...y(t − p + 1)y(t − p)

The system is stable if and only if maxi|λi (A)| < 1. The characteristic

polynomial have Ak as a coefficient so the condition will be nonlinear in A

14 / 25

Page 15: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Previous Works of Stability condition

Researcher Method Difference in paperJ. Mari et al., Apply Lyapunov theory Too complicate2000 to vector ARMAS. L. Lacy et al.,2003

V. Cerone et al., Jury’s test to guarantee MIMO linear system2010 BIBO stability on

SISO LTI system

L. Buesing et al., Apply Lyapunov theory structure of A2012 on LDS model to estimate A

that comply with ATA ≺ I

K. Turksoy et al., Use Gershgorin circle theory similar2013 on ARMAX

15 / 25

Page 16: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Sufficient Condition for stability

Spectral radius and Induced norm

From spectral radius ρ(A) = maxi|λi (A)| then the system is stable if

ρ(A) < 1 and by the inequality

ρ(A) ≤ ‖A‖

if assume that ‖A‖ < 1 it will affect ρ(A) < 1 when ‖A‖ is a inducednorm

We choose the infinity-norm of A to be the sufficient condition for stability.

‖A‖∞ ≤ 1

Due to structure of A‖A‖1 ≤ 1 and ‖A‖2 ≤ 1 lead to meaningless which is A1, . . . ,Ap−1

are equal to zero.

‖A‖F ≤ 1 is impossible16 / 25

Page 17: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

We can estimate a stable model parameter with Granger causalitycondition by solving this problem.

minimizeA

‖Y − AH‖2F

subject to A =

A1 A2 . . . Ap−1 Ap

I 0 . . . 0 00 I . . . 0 0...

.... . .

......

0 0 . . . I 0

,‖A‖∞ ≤ 1,

(Ak)ij = 0, (i , j) ⊂ {1, . . . , n}x{1, . . . , n}

The problem is convex in quadratic form and can be solved by many solver.

17 / 25

Page 18: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Results

-1 -0.5 0 0.5 1

-1

-0.5

0

0.5

1

(c) no constraint

-1 -0.5 0 0.5 1

-1

-0.5

0

0.5

1

(d) with Granger causality constraints

Figure 1: Positions of the eigenvalues of A on complex plane

18 / 25

Page 19: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Results

-1 -0.5 0 0.5 1

-1

-0.8

-0.6

-0.4

-0.2

0

0.2

0.4

0.6

0.8

1

Figure 2: Positions of the eigenvalues of A on complex planewith Granger causality and stability constraints

19 / 25

Page 20: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Conclusion

ML estimation of AR model

with closed-form solution

Wald test

on 𝐴

Estimation of AR Subject to

Granger causality condition

Estimation of AR Subject to Granger

causality condition + Stability condition

Is the model stable?

Time Series Data

𝐴, Σ Zero pattern of 𝐴

AR model with Granger causality

yes

noStable AR modelwith Granger causality

Sparsity pattern of 𝐴 Sparsity pattern of 𝐴

Some eigenvalues of 𝒜lie outside the unit circle

All eigenvalues of 𝒜lie on the unite circle Sparsity pattern of 𝐴

20 / 25

Page 21: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Why we have to check the stability?

𝒜 |𝜆𝑚𝑎𝑥(𝒜)| < 1

𝒜 𝒜 ∞ < 1

Estimated 𝒜 withoutstability condition

Estimated 𝒜 withstability condition

21 / 25

Page 22: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

reference

L. Buesing, J. H. Macke, and M. Sahani.Learning stable, regularised latent models of neural populationdynamics.Network: Computation in Neural Systems, 23(1-2):24–47, 2012.

V. Cerone, D. Piga, and D. Regruto.Bounding the parameters of linear systems with stability constraints.In American Control Conference (ACC), 2010, pages 2152–2157.IEEE, 2010.

W. H. Greene.Econometric analysis, 2008.Upper Saddle River, NJ: Prentice Hall, 24:25–26.

J. Mari, P. Stoica, and T. McKelvey.Vector arma estimation: A reliable subspace approach.Signal Processing, IEEE Transactions on, 48(7):2092–2104, 2000.

22 / 25

Page 23: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

S. L. Lacy and D. S. Bernstein.Subspace identification with guaranteed stability using constrainedoptimization.Automatic Control, IEEE Transactions on, 48(7):1259–1263, 2003.

J. Songsiri.Sparse autoregressive model estimation for learning granger causalityin time series.In Acoustics, Speech and Signal Processing (ICASSP), 2013 IEEEInternational Conference on, pages 3198–3202. IEEE, 2013.

K. Turksoy, E. S. Bayrak, L. Quinn, E. Littlejohn, and A. Cinar.Guaranteed stability of recursive multi-input-single-output time seriesmodels.In American Control Conference (ACC), 2013, pages 77–82. IEEE,2013.

23 / 25

Page 24: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

Q&A

24 / 25

Page 25: Exploring Granger Causality for Time series via Wald Test ...jitkomut.eng.chula.ac.th/pdf/talk-eecon2016.pdf · Exploring Granger Causality for Time series via Wald Test on Estimated

THANK YOU

25 / 25