0% found this document useful (0 votes)
83 views

HW 04 Ans

This document is an assignment answer sheet for a risk management and regulation class. It provides solutions to 4 problems involving estimating drift and volatility parameters for stock prices modeled as geometric Brownian motions. Graphs of the estimated parameters over time using different window sizes and exponential weighting show the 2-year results are very unstable while 10-year are too smooth, and 5-year and exponentially weighted results using larger λ values look most stable. The drift estimates are much noisier than volatility.

Uploaded by

DelphineChen
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
83 views

HW 04 Ans

This document is an assignment answer sheet for a risk management and regulation class. It provides solutions to 4 problems involving estimating drift and volatility parameters for stock prices modeled as geometric Brownian motions. Graphs of the estimated parameters over time using different window sizes and exponential weighting show the 2-year results are very unstable while 10-year are too smooth, and 5-year and exponentially weighted results using larger λ values look most stable. The drift estimates are much noisier than volatility.

Uploaded by

DelphineChen
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 12

Math G4802: Risk Management and Regulation

Assignment 4 Answer Sheet

Department of Mathematics
Columbia University

Harvey J. Stein
Head, Regulation and Credit Risk
Quantitative Risk Analytics
Bloomberg LP

Fall 2015
Compilation: October 14, 2015 at 02:13

Due next Thursday by 1:00 pm.


For help, see the TAs:
Jiao Li [email protected]
Yiding Lyu [email protected]
Mario Zhu [email protected]

Math G4802

Assignment 4 Answer Sheet

Fall 2015

1. Parametric VaR, 1 stock The mean and standard deviation of the daily log returns
of a stock are S 0.03% and 1.30%, respectively. Suppose the stock follows a geometric
Brownian motion with parameters and , so that
dSt = St dt + St dWt
where Wt is a standard Brownian motion.
(a) What are good estimates for the drift and volatility, and , respectively?
Solution:
Denote the mean and the standard deviation of the daily log returns by
and

. Let t be the length of the return period. The relationship between the log
return statistics and the GBM parameters is given by:

=
/ t
=
/t + 2 /2
Plugging in
= 0.0003,
= 0.013, and t = 1/252, we get:

=
252 = 0.20637
=
252 + 2 /2 = 0.09689

Therefore, = 20.6% and = 9.69%.

(b) What is the 1 day 99% VaR of a position of 10,000 shares in the stock if the current
stock price is $55 a share?
Solution: See hw04p1.ods.
The formula for the VaR of a stock is:
VaR(S, T, p) = S0 S0 eX

2
X = T 1 (1 p) + ( )T
2
In our case, S0 = 55, T = 1/252, p = 0.99, = 20.6% and = 9.69%. The
VaR for 10,000 shares of S will be 10, 000 VaR(S, T, p).

Page 2 of 12

Math G4802

Assignment 4 Answer Sheet

Fall 2015

The exponent is given by:

2
X = T 1 (1 p) + ( )T
2
p
0.2062
)(1/252)
= 0.206 1/2521 (0.01) + (0.0969
2
= 0.0129768 1 (0.01) + 0.0003003254
= 0.0129768 (2.326347874) + 0.0003003254
= 0.029888
The VaR is then
10, 000 $55 (1 e0.029888 ) = $16, 195

2. Parametric VaR, 2 stocks


We have 400 shares of stock 1 and 250 shares of stock 2. Stock 1s current price is $50 per
share and stock 2s current price is $100 per share. Stock 1 and 2 follow GBM with drift
4% and 2% and volatility 35% and 30%, respectively, each driven by Brownian motions
with 20% correlation. What is the two week 98% VaR of the portfolio? Calculate it
parametrically assuming that the portfolio is normally distributed.
Solution:
See hw04ParaPort.m.
We compute the mean and variance of the portfolio at time t = 10/252 using the
formulas derived in class. Assuming the portfolio at time t is normal with the same
mean and variance, we then move down from the mean by the appropriate number
of standard deviations, yielding:
V_0
E[V_t]
E[V_t^2]
var[V_t]
sd[V_t]
norminv(1-p)

:
45000.00
:
45051.62
: 2034679229.06
:
5030729.68
:
2242.93
:
-2.0537

Page 3 of 12

Math G4802

Assignment 4 Answer Sheet

Fall 2015

VaR by normal approximation:


VaR[V_t]
:
4554.79

3. Calibration
For this and the remaining problems, let A be Apple stock, and I be IBM stock. Their
historical values are in the StockPrices.ods spreadsheet.
Let (S, t, l) and (S, t, l) be the estimated drift rate (mean) and relative volatility
parameters for a GBM process S computed on date t using the last l years worth of
observations (i.e. assume dS = Sdt + SdW and that and are constant over that
set of observations).
Tabulate and graph (S, t, l) and (S, t, l) for S = A and S = I for t ranging over the
last 20 years, and l being 2, 5, and 10 years, using unweighted fitting. Use adjusted
closing prices.
Why are the computed parameters over time comparable even though the value invested
varies?
How stable do the results look?

Solution:
Solution for this problem and the next one (to be split up).
See spreadsheet hw04est.ods and hw04est.gp.
This and the next problem can be done with spreadsheets, but I dont recommend
it. If you try you will see that the spreadsheets get quite big. They are usable in
Excel, but extremely slow in LibreOffice.
Steps for windowed means and averages:
1. Copy the data from the data spreadsheet
2. Set up columns with log returns and log returns squared
3.
For each window, the GBM vol () is the STDEV() of the log returns times
252.
4. For each window, the GBM drift () is the average of the log returns times 252
+ 2 /2.

Page 4 of 12

Math G4802

Assignment 4 Answer Sheet

Fall 2015

5. Set up a column with these formulas on the next 252 2 log returns to the
GBM parameters for 2 year windows
6. Do the same for 252 5, and 252 10 to get the GBM parameters for the 5
year and 10 year windows.
Steps for exponentially weighted means and variances (easy, but slow method):
1. Make a column of the powers of lambda
2. Use SUMPRODUCT() to compute the dot product of the entire log return
column starting at that date with the powers of lambda.
3. For large enough lambda, the weights drop off fast enough that we can approximate with a large window, such as with 3,000 samples.
4. Dont forget to divide by the sum of the powers of lambda to get the weighted
average
5. For the sample sigma, do the same on the square of the log returns, then
subtract the square of the mean, and take the square root.
6. Then apply the formulas for converting the sample mean and average to the
GBM parameter estimates.
I dumped the results to a .csv file and plotted them with the above gnuplot script.
Here are the results:
APPL vols
90
2yr
5yr
10yr
80

70

60

50

40

30

20
1994

1996

1998

2000

2002

2004

2006

Page 5 of 12

2008

2010

2012

2014

2016

Math G4802

Assignment 4 Answer Sheet

Fall 2015

APPL mu
140
2yr
5yr
10yr

120
100
80
60
40
20
0
-20
-40
-60
1994

1996

1998

2000

2002

2004

2006

2008

2010

2012

2014

2016

IBM vols
50
2yr
5yr
10yr

45

40

35

30

25

20

15

10
1994

1996

1998

2000

2002

2004

2006

Page 6 of 12

2008

2010

2012

2014

2016

Math G4802

Assignment 4 Answer Sheet

Fall 2015

IBM mu
70
2yr
5yr
10yr

60
50
40
30
20
10
0
-10
-20
-30
1994

1996

1998

2000

2002

2004

2006

2008

2010

2012

2014

2016

IBM vols, exponential weighting


90
l=0.94
l=0.97
l=0.9968117641
l=0.9987234838
l=0.9993615381

80
70
60
50

40
30
20
10
0
1994

1996

1998

2000

2002

2004

2006

Page 7 of 12

2008

2010

2012

2014

2016

Math G4802

Assignment 4 Answer Sheet

Fall 2015

IBM mu, exponential weighting


400
l=0.94
l=0.97
l=0.9968117641
l=0.9987234838
l=0.9993615381

300

200

100

-100

-200

-300

-400
1994

1996

1998

2000

2002

2004

2006

2008

2010

2012

2014

2016

IBM vols, exponential weighting vs windows


50
2 yr
5 yr
10 yr
l=0.9968117641
l=0.9987234838
l=0.9993615381

45

40

35

30

25

20

15

10
1994

1996

1998

2000

2002

2004

2006

Page 8 of 12

2008

2010

2012

2014

2016

Math G4802

Assignment 4 Answer Sheet

Fall 2015

IBM mu, exponential weighting vs windows


80
2 yr
5 yr
10 yr
l=0.9968117641
l=0.9987234838
l=0.9993615381

60

40

20

-20

-40
1994

1996

1998

2000

2002

2004

2006

2008

2010

2012

2014

2016

APPL vols, exponential weighting


300
l=0.94
l=0.97
l=0.9968117641
l=0.9987234838
l=0.9993615381

250

200

150

100

50

0
1994

1996

1998

2000

2002

2004

2006

Page 9 of 12

2008

2010

2012

2014

2016

Math G4802

Assignment 4 Answer Sheet

Fall 2015

APPL mu, exponential weighting


1000
l=0.94
l=0.97
l=0.9968117641
l=0.9987234838
l=0.9993615381

800
600
400
200
0
-200
-400
-600
-800
-1000
1994

1996

1998

2000

2002

2004

2006

2008

2010

2012

2014

2016

APPL vols, exponential weighting vs windows


100
2 yr
5 yr
10 yr
l=0.9968117641
l=0.9987234838
l=0.9993615381

90

80

70

60

50

40

30

20
1994

1996

1998

2000

2002

2004

2006

Page 10 of 12

2008

2010

2012

2014

2016

Math G4802

Assignment 4 Answer Sheet

Fall 2015

APPL mu, exponential weighting vs windows


140
2 yr
5 yr
10 yr
l=0.9968117641
l=0.9987234838
l=0.9993615381

120
100
80
60
40
20
0
-20
-40
-60
1994

1996

1998

2000

2002

2004

2006

2008

2010

2012

2014

2016

Computed parameters are comparable over time because they are for GBM. In GBM,
the drift and variance are relative to the stock price (i.e. expressed as a percentage
of the stock price). Hence, if the parameters are stable, then they are independent
of the level of the stock and hence are comparable over time.
Observations:
The 2 year results are very jumpy.
The 10 year results look too smooth they adapt very slowly to changing
environments.
The 5 year results look usable.
The = .94 and = .97 results are far too noisy to be useful.
The drift estimates are much more noisy than the volatility estimates with the
same size window.
The drift estimates have a much greater variance than the volatility estimates.
Different choices of parameters (lambda and window size) yield substantially
different estimates for the drift and volatility.

The noise exhibited in the drift estimates indicates why drifts are often assumed to
be zero in calculations.

Page 11 of 12

Math G4802

Assignment 4 Answer Sheet

Fall 2015

4. Exponential weighting
Repeat the previous problem using exponential weighting, with = 0.94 and = 0.97.

Solution:
See previous solution which includes results for this problem.

Page 12 of 12

You might also like