Lecture 2
Lecture 2
Mathematical Model
u System y
1 1
y (t + 1) - y (t ) = - y (t ) + u (t )
RA A
1 1
y y (t + 1) = ( - + 1) y (t ) + u (t )
Resistance (R) RA
A
f1 y1
24
A Dynamics System:
The state at time t depends on time t-1.
It has a memory!
1. 25
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
25
1
Copyright Protected (Do Not Copy)
In reality, physical modeling could be difficult or impossible, and we have to work with the observed
data (System Identification, Parameter Estimation).
w
u System y
10
Input y (t + 1) = f1 y (t ) + y 1u (t ) Output
30
5
20
0
10
-5 0
-10 -10
0 50 100 150 200 250 300 0 50 100 150 200 250 300
• In the financial systems, we can’t measure inputs either! And Noise to Information Ratio is high.
w
Financial y
System 30
Output
20
10
0
-10
0 50 100 150 200 250 300
1. 26
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
26
(a) y (t + 1) = f1 y (t ) + y 1u (t ) yt = f ( yt -1 , ut )
1. 27
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
27
2
Copyright Protected (Do Not Copy)
(a) y (t + 1) = f1 y (t ) + y 1u (t ) yt = f ( yt -1 , ut )
1. 28
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
28
Xk 8
-2
-4
-6
k
-8
-10
0 1000 2000 3000 4000 5000 6000 7000
10 10 10 10
6 Xk 8
6 Xk
8
6 Xk
8
6 Xk
4 4 4 4
2 2 2 2
0 0 0 0
-2 -2 -2 -2
-4 -4 -4 -4
-6
Xk-10
-6 -6
-8 -8 -8 -8
29
3
Copyright Protected (Do Not Copy)
Definition
Autocovariance Function:
Let {Xt} be a time series. The autocovariance function of process {Xt} for all
integers r and s is:
g X (r , s ) = cov( X r , X s )
g X (r , s ) = E[( X r - E ( X r ))( X s - E ( X s ))]
g X (r , s ) = E[ X r X s - X r E ( X s ) - X s E ( X r ) + E ( X r ) E ( X s )]
g X (r , s) = E ( X r X s ) - E ( X r ) E ( X s ) - E ( X s ) E ( X r ) + E ( X r ) E ( X s )
g X (r , s) = E ( X r X s ) - E ( X r ) E ( X s ) =0
1. 30
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
30
Autocovariance Function
g X (0) g X (2)
Sample Autocovariance Function
0 2 4 6 8 10 12 14 16 18 20
Lag
g X (1)
What if the parameters change over time?
1. 31
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
31
4
Copyright Protected (Do Not Copy)
Definition
Note:
Stationary Process: A strict (strong) stationary time series
A time series {Xt} is stationary (weakly) if: {Xt , t=1,2,…,n}
is defined by the condition that realizations
2
1. E ( X t ) < ¥ Finite Variance (X1, X2, …, Xn) and (X1+h, X2+h, …, Xn+h)
have the same joint distributions for all
32
Definition
Note:
1. 33
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
33
5
Copyright Protected (Do Not Copy)
Stationary Process
1. 34
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
34
Stationary Process
80
60
40
20
Non-Stationary Process
0
-20
0 50 100 150 200 250 300
-2
-4
Mean-Reversion Stationary Process
-6
0 50 100 150 200 250 300
1. 35
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
35
6
Copyright Protected (Do Not Copy)
3. Fit a model
If bad
4. Perform diagnostic tests (residual analysis,…)
transformations performed in 2.
36
ìs 2 r=s (s 2 < ¥)
g X (r , s) = í
î 0 otherwise
{Xt} is called White Noise and it is written as WN(0, s )
2
0
0
WN
-5 -5
Xk-1
-5 0 5
0 1000 2000 3000 4000 5000 6000 7000
1. 37
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
37
7
Copyright Protected (Do Not Copy)
E( X t ) = 0
ìs 2 r=s (s 2 < ¥)
g X (r , s) = í
î0 otherwise
1. 38
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
38
100 10
Sk
5
Random W alk
0
0
-5
-100
-10
Sk-1
0 1000 2000 3000 4000 5000 6000 7000 -10 -5 0 5 10
1. 39
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
39
8
Copyright Protected (Do Not Copy)
St = å j =1 X j
t
IID(0, s )
2
{Xt}
1. 40
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
40
Yt = X t + qX t -1
Where q could be any constant. This time series model is called a first-
order moving average process, denoted MA(1).
The term “Moving Average” comes from the fact that Yt is constructed
from a weighted sum of the most recent values of Xt.
q =0.5
4
Yk
2
-2
-4
Yk-1
0 1000 2000 3000 4000 5000 6000 -4 -2 0 2 4
1. 41
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
41
9
Copyright Protected (Do Not Copy)
1. 42
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
42
Autoregressive Process
Let {Zt } be WN(0, s 2), and consider the process
X t = fX t -1 + Z t
Where |f |<1 and Zt is uncorrelated with Xs for each s<t. This time series
model is called a first-order Autoregressive process, denoted AR(1).
It is easy to show that E(Xt)=0
5
10
f=0.7 5
Xk
0
0
-5
-5
-10
Xk-1
0 100 200 300 400 500 600 700 -10 -5 0 5 10
1. 43
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
43
10
Copyright Protected (Do Not Copy)
1. 44
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
44
-5
(Integrated Process)
te -10
Sk-1
ra -10 -5 0 5 10
White Noise te g
In
ìs 2 r=s
g X (r , s) = í 4
î0 otherwise Yt = X t + qX t -1 Yk
2
5 Moving Average
Xk Moving Average
0
-2
0
-4
Yk-1
-4 -2 0 2 4
Au
-5
Xk-1 to
Re
gr
-5 0 5 es
s io 10
n
X t = fX t -1 + Z t 5
Xk
Auto Regressive
0
-5
-10
Xk-1
-10 -5 0 5 10
45
11
Copyright Protected (Do Not Copy)
X t = fX t -1 + Z t
30 30
f =1
20 20
10 10
0 0 Random Walk
-10 -10
0 50 100 150 200 250 300 -10 0 10 20 30
10 10
f = 0.9
5 5
0 0
-5 -5 AR(1)
-10 -10
0 50 100 150 200 250 300 -10 -5 0 5 10
4 4
f = 0.1
2 2
0 0
-2 -2 AR(1)
-4 -4
0 50 100 150 200 250 300 -4 -2 0 2 4
1. 46
Farshid Maghami Asl G63.2707 - Financial Econometrics and Statistical Arbitrage
46
Before we start…
47
12