0% found this document useful (0 votes)
19 views37 pages

03 VaR

Uploaded by

alicea112233
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
19 views37 pages

03 VaR

Uploaded by

alicea112233
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 37

Value at Risk

MF 731 Corporate Risk Management

1 / 37
Outline

VaR for normal distributions.

Estimating VaR from data.

Review from last time.

Computing VaR for portfolio losses.

Time aggregation of VaR.

Backtesting VaR.

2 / 37
Value at Risk (VaR)

As we saw last week: let L be a r.v. with CDF F .


For a confidence α ∈ (0, 1), we define

VaRα := inf [` ∈ R | P [L > `] ≤ 1 − α]


= inf [` ∈ R | F (`) ≥ α]
= “F −1 (α)00

Also called the quantile of F .

While defined for any α ∈ (0, 1), we typically consider


α ∈ (.95, 1).

3 / 37
VaRα = F −1(α)

For continuous and discrete distributions

4 / 37
VaR for Normal Random Variables

Claim: L ∼ N(µ, σ 2 ) =⇒ VaRα (L) = µ + σN −1 (α).


N: standard normal cdf.

Proof (easy!)
Note we can write L = µ + σZ for Z ∼ N(0, 1).

Then, using the scaling property of VaR:

VaRα (L) = µ + σVaRα (Z ) = µ + σN −1 (α)

We will use this result A LOT going forward.

5 / 37
VaR From Data (again)

VaR for normal F is important to know.


Another important case: empirical distribution Fne .
{`i }i=1,...,n : data points.
Fne : empirical distribution.
1
Mass n at each `i (including repetition).

Claim: VaRα (Fne ) = `(dnαe) .


`(1) ≤ `(2) ≤ ... ≤ `(n) ordered values.
dnαe = min [k ∈ N | k ≥ nα]: “ceiling”.
This works even if some data points are the same.

6 / 37
Proof of VaRα (Fne ) = `(dnαe)

Assume for simplicity `(1) < `(2) < · · · < `(n) .


I.e.: no repetition.
dnαe
Fne (dnαe) = n1 × # i | `i ≤ `(dnαe) =

n
≥ α.

Now, let ` < `(dnαe) . Since Fne is a step function:


dnαe−1
Fne (`) ≤ Fne (`(dnαe−1) ) = n
< α.

Thus, `(dnαe) is the value at risk.


This is how we defined F −1 for discrete distributions.

7 / 37
VaR for Portfolio Losses
We can use VaR for normal and empirical dist’s to
obtain portfolio loss VaR in a wide range of models.
Recall: Lt+∆ = −(Vt+∆ − Vt ) is the portfolio loss.
Goal: estimate VaRα (Lt+∆ ) at time t.

We estimate portfolio losses and hence VaR using:


Historical data, Analytic methods, Monte Carlo.

For each method, we may use


Full, linear, or quadratic losses.
quad quad
Lt+∆ = l[t] (Xt+∆ ), Llin lin
t+∆ = l[t] (Xt+∆ ), Lt+∆ = l[t] (Xt+∆ ).

Trade-off: accuracy versus ease of implementation.


8 / 37
VaR from Portfolio Losses

Historical (H), Monte Carlo (MC) methods produce


loss data.
 n
H: `i = l[t] (xt−(i−1)∆ ) i=1 where {xt−i∆ } are the historical
changes in risk factors.
 i n  i
MC: `i = l[t] (Xt+∆ ) i=1 where Xt+∆ are i.i.d. samples
of the risk factor changes Xt+∆ .
lin quad
l[t] : one of l[t] , l[t] or l[t] .

Once we have the data, getting the VaR is easy!


VaR
\α = `(dnαe) : estimator for VaRα (Lt+∆ ).

9 / 37
Historical Example: Stock Portfolio

t = 9/1/21, Vt = $1M, 33% AAPL, 67% MSFT.

Historical daily log returns from 9/1/16 − 8/31/21.

10 / 37
MC Example: Apple Call Option
Sell a call option (K , T ), delta-hedge with stock.
BS model, constant hedging position over [t, t + ∆].

Lt+∆ = − ht (St+∆ − St ) − C BS (t + ∆, St+∆ ) − C BS (t, St ) .

Simulation inputs (physical measure!)


10
T − t = .292, ∆ = 252 , St = 152.51, K = 170.
r = 0.119%, µ = 16.91%, σ = 49.07%.

Loss distribution (100 calls). VaR


\ .95 = 300.6.

11 / 37
Analytical Method
F
Assumes Xt+∆ ∼t F and computes VaR off F .
F
E.g.: equities, log returns Xt+∆ ∼t N (µt+∆ , Σt+∆ ).
 (i)

Pd (i) Xt+∆

Lt+∆ = − i=1 θt e − 1 = −θtT e Xt+∆ − 1 .
Pd (i) (i)
Llin
t+∆ = − i=1 θt Xt+∆ = −θtT Xt+∆
(i) (i) (i)
θt = λt St : dollar position.

VaR for linearized losses:


Ft 
Llin T T
t+∆ ∼ N −θt µt+∆ , θt Σt+∆ θt .
p
θtT Σt+∆ θt N −1 (α).

VaRα Llin T
t+∆ = −θt µt+∆ +

12 / 37
Equity Example Continued
VaR for full losses estimated via simulation:
For m = 1, . . . , M:
m F
Sample Xt+∆ ∼t N(µt+∆ , Σt+∆ ).
m 
Set `m = Lm T
t+∆ = −θt e
Xt+∆
−1 .

VaRα (Lt+∆ ) = `(dMαe) .

Ex: AAPL/MSMF portfolio from above.


Estimate µt+∆ , Σt+∆ using data from 9/1/16 − 8/31/21
VaR estimates
Empirical: $24, 138.5.
Full normal simulated: $25, 707.1.
Linearized normal: $26, 090.3.

13 / 37
VaR and Time Aggregation

The basic problem:

Our methods for estimating VaR are typically applied to


one-day horizons.

The regulatory requirement is to calculate VaR for a ten-day


horizon.

14 / 37
Time-Aggregation

How do we go from a one day to ten day horizon?


One idea, using historical data:
Use current methodology taking data from non-overlapping
10 day periods.
Problem: not enough data. E.g.: 4 years historical data
yields just 100 such periods.
VaR.99 is second largest loss.

Work-around(??): use overlapping periods. BUT


This introduces complicated dependencies.

What do we do?
15 / 37
Square Root of Time
Industry convention:

J day VaRα = J× one day VaRα .

Where is this coming from?


Equity portfolio, constant holdings over [t, t + J∆],
linearized losses, log-return risk factors.
P 
J
Llin
t+J∆ = −θtT j=1 Xt+j∆ .

F
Next, assume {Xt+j∆ }Jj=1 i.i.d. ∼t N(0, Σ).
PJ F
This implies j=1 Xt+j∆ ∼t N (0, JΣ).

16 / 37
Square Root of Time

Ft 
Thus, Llin
t+J∆ ∼ J 0, Nθt
T
Σθt .

 q T
VaRα Llin
t+J∆ = Jθt Σθt N −1 (α);
√ q
= J × θtT Σθt N −1 (α);

= J × VaRα Llin

t+∆ .

Square root of time horizon multiplied by 1 period VaR.

Industry convention: assume this scaling in general.

17 / 37
Square root of Time Rule

Included in Basel-I (1996 ammend.) and Basel-II.


However: only from going from 1 to 10 day VaR.
Not from e.g. 1 to 100 day VaR.

Little theoretical evidence to support the rule in


non-Gaussian, i.i.d. models.
Kaufmann, et. al. (’04,’05,’07): OK for unconditional VaR,
longer time horizons.
Frey, et. al. (’00): not OK for conditional VaR, shorter time
horizons.

18 / 37
Time Aggregation: MC
We can avoid such approximations using MC.
Idea: if Vt = f (t, Zt ) then
   
Lt+J∆ = − f t + J∆, zt + Jj=1 Xt+k∆ − f (t, zt )
P
P 
J J
= l[t] j=1 Xt+j∆
J
l[t] (x) = − (f (t + J∆, zt + x) − f (t, zt )).

Method:
Postulate a model for the process {Xt+j∆ }Jj=1 .
For m = 1, . . . , M
n oJ
m
Sample Xt+j∆ .
j=1
P 
J J m
Compute `m = l[t] j=1 t+j∆ .
X

Output the estimator VaR


\α = `(dMαe) .
19 / 37
MC and Time Aggregation

J
How do we obtain the loss operator l[t] (x)?
Issue: for J >> 1 we must allow for position changes.

Ex: equity portfolio.


Set Tj = t + j∆ and Lj as loss over [Tj−1 , Tj ].
Positions over [Tj−1 , Tj ] chosen at Tj−1 .
 
(i) (i) (i)
Lj = − di=1 λTj−1 STj − STj−1 and Lt+J∆ = Jj=1 Lj .
P P

How do we account for changing positions?

What rule can we apply at t to know position at Tj−1 ?

20 / 37
MC and Time Aggregation

For constant positions λTj−1 ≡ λ


 
Pd (i) (i) (i)
Lj = − i=1 λ STj − S Tj−1 .

Telescoping sum.
   PJ (i) 
(i) (i) (i) (i) j=1 XTj
Pd (i)
Pd
Lt+J∆ = − i=1 λ STJ − St = − i=1 λ St e − 1 .

For constant weights wTj−1 ≡ w :


 (i) 
Pd (i) XT
Lj = −VTj−1 i=1 w e j −1 .
PJ
Lt+J∆ = j=1 LTj .

21 / 37
MC Example: Hedged Call Option

Self-financing strategy over [t, t + J∆].


Over [T0 , T1 ] = [t, t + ∆] (first period)
We are short a call option with strike κ, maturity T .
We are long hT0 = ∂x C BS (T0 , ST0 ) shares of the stock.
We hold YT0 = $0 (no position) in the bank account with rate r .

VT0 = hT0 ST0 + YT0 − C BS (T0 , ST0 ).


| {z } |{z} | {z }
stock bank option

VT1 = hT0 ST1 + YT1 = YT0 e r ∆ − C BS (T1 , ST1 ).


| {z } | {z } | {z }
stock bank option

L1 = −(VT1 − VT0 ).

22 / 37
Hedged Call Option
For j = 2, ..., J consider [Tj−1 , Tj ].
“Yesterday’s closing” dollar positions (end of [Tj−2 , Tj−1 ])
(stock): hTj−2 STj−1 .
(bank): YTj−1 .
“Today’s opening” dollar positions (beginning of [Tj−1 , Tj ])
(stock): hTj−1 STj−1 where hTj−1 = ∂S C BS (Tj−1 , STj−1 ).

(bank) : YTnew
j−1
= YTj−1 + hTj−2 − hTj−1 STj−1 .

At today’s close (end of [Tj−1 , Tj ])


VTj = hTj−1 STj + YTj = YTnew
j−1
e r ∆ − C BS (Tj , STj ).
| {z } | {z } | {z }
stock bank option

Lk = − VTj − VTj−1 .
STj
 
Simulate by sampling XTj = ln STj−1 .
23 / 37
Hedged Call Option

Simulation inputs.
1
T − t = .292, ∆ = 252
, J = 10, κ = 170.

St = 152.51, r = 0.119%, µ = 16.905%, σ = 49.07%.

VaR
\ .95 ’s (100 calls)

Full 10-day simulation: 86.76.



10× one day VaR: 92.97 (slight over-estimation).

Compare with a VaR of 300.6 without rebalancing.

24 / 37
Backtesting VaR

We have numerous methods for estimating at t the


VaR of our losses over [t, t + ∆].

Whatever method we use, over time we produce a


series of estimates
n to
VaRα
\ .
t=0,∆,2∆,...

We need a way to test our estimates to see if our


methodology/model is sound.

This is where backtesting comes into play.

25 / 37
Backtesting VaR: Theory

Suppose we have a model for {Lt+∆ }t .


t ∈ {0, ∆, 2∆, . . . }.
Ft : information at t.
Lt+∆ is known using Ft+∆ but not using Ft .

We can then identify


VaRtα = inf τ ∈ R | P Lt+∆ ≤ τ Ft ≥ α .
  

VaRtα is a RANDOM VARIABLE, known using Ft .

We say the event ω ∈ Ω | Lt+∆ (ω) > VaRtα (ω) is



a VaR violation or exception or exceedance.
26 / 37
Backtesting VaR: Theory
Write It+∆ := 1Lt+∆ >VaRtα .
Assuming a continuous conditional dist:
E It+∆ Ft = P Lt+∆ > VaRtα Ft = 1 − α.
   

F
=⇒ It+∆ ∼t B(1 − α).

Furthermore: {It+∆ }t are i.i.d. (t < s)


Write Gα as the cdf of a B(1 − α) r.v..

  
P [It+∆ ≤ τ1 , Is+∆ ≤ τ2 ] = P It+∆ ≤ τ1 P Is+∆ ≤ τ2 Ft
= Gα (τ2 )P [It+∆ ≤ τ1 ]
= Gα (τ1 )Gα (τ2 ).

27 / 37
Backtesting VaR: Theory

Consequence of i.i.d. {It+∆ }t with It+∆ ∼ B(1 − α).

Fix t0 , set Tj = t0 + j∆ and define


PJ
NtJ0 := j=1 It0 +j∆ .

# of exceedances over the J periods [T0 , T1 ], ..., [TJ−1 , TJ ].

Ft
By construction, NtJ0 ∼0 B(J, 1 − α).
Binomial r.v. with J trials (periods), 1 − α probability of
success (exceedance).

28 / 37
Backtesting VaR: Practice

We use the binomial property to test our model.

Basic idea:

We should observe bigger losses than our forecasted VaR


with probability 1 − α.

E.g.: for ∆ = 1d and α = .95, in one year we should see


approximately 252 × .05 = 12.6 exceedances.

If we see much more or much less, our model needs


adjusting.

29 / 37
Backtesting VaR: Practice

The test

VaRtα was computed using our model.

In reality, we use our model to estimate the “true” VaR:


n to
I.e. we produce estimates VaR
\ α .
t

We then use the realized losses L̂t+∆ to compute the


realized violations Iˆt+∆ = 1L̂ >VaR
\ .
t
t+∆ α

30 / 37
Backtesting VaR: Practice

Null hypothesis: our model is accurate.


n oJ
Iˆt0 +j∆ are samples of i.i.d. B(1 − α) r.v.
j=1

PJ
As such, for large J (recall NtJ0 = j=1 It0 +j∆ )
J
N̂ −J(1−α)
If Zb := √t0 then Zb ≈ N(0, 1) in dist..
Jα(1−α)

1 − β confidence interval (CI)


h i
P τ−β ≤ N̂tJ0 ≤ τ+β ≈ 1 − β.
β
p
τ± := J(1 − α) ± z1− β Jα(1 − α) where zγ = N −1 (γ).
2

31 / 37
Backtesting VaR: Practice
To test the null hypothesis:
We take in the VaR confidence α, # of sample days J, CI
confidence 1 − β.
We then
Count the number of exceedances N̂tJ0 over [T0 , TJ ].
If this number lies outside the 1 − β CI we reject the null
hypothesis at the 100(1 − β)% confidence.

E.g.: α = .95, J = 250, β = .05.


We want N̂tJ0 ∈ (5.75, 19.25)
If N̂tJ0 ≥ 20: model too optimistic (VaR not high enough).
If N̂tJ0 ≤ 5: model too pessimistic (VaR too high).

32 / 37
Backtesting Example

S&P 500 daily price data from 8/31/2007 to 8/31/2017.

N = 2518 data points.

Hypothetical portfolio:

100% S&P stock, portfolio size a constant $1.

l[s] (Xs+∆ ) = l(Xs+∆ ) = −(e Xs+∆ − 1).

t
Produce the estimates VaR
\α two ways.

33 / 37
Backtesting Example

Method one: rolling empirical distribution

For each t, use past M days return data to compute


empirical loss distribution.

 M
Use past returns to obtain `tm = l[t] (xt−(m−1)∆ ) m=1
.

t
t
Estimate VaR
\ α = `(dMαe) .

Compare VaR with realized loss l[t] (xt+∆ ).

34 / 37
Backtesting Example

Method two: normal returns with rolling EWMA.


For each t update mean/variance estimates via EWMA
µ̂t+∆ = λµ̂t + (1 − λ)xt .
2
σ̂t+∆ = θσ̂t2 + (1 − θ)(xt − µ̂t )2 .
t  
\α = − e µ̂t+∆ +σ̂t+∆ N −1 (1−α) − 1 .
Estimate VaR

F 2
Explicit full loss VaR formula when Xt+∆ ∼t N(µ̂t+∆ , σ̂t+∆ ) is
one-dimensional.
Make sure you can derive this!

Compare VaR with realized loss l[t] (xt+∆ ).

35 / 37
Backtesting Example

Results for α = .95, β = .05, J = N − M = 1508.

Average: 75.4. Low CI: 58.81. High CI: 91.99.

Exceedances

Empirical: 44.

EWMA: 79.

What do we think is happening?

EWMA ok but Empirical too pessimistic.

36 / 37
Backtesting Example

Exceedances over time

Independence assumption appears to be violated.

37 / 37

You might also like