190 likes | 200 Views
This text provides an overview of option sensitivities (Delta, Gamma, Vega, etc.) and implied volatility in finance. It covers the computation of historical volatility, calibrating a binomial tree, and the Black-Scholes-Merton model. VBA code for binomial European call and implied volatility calculations is included.
E N D
From Binomial to Black-Scholes-Merton Option Sensitivities (Delta, Gamma, Vega , etc) Implied Volatility Finance 30233, Fall 2017 The Neeley School S. Mann
s= annualized standard deviation of asset rate of return Historical Volatility Computation 1) compute weekly returns 2) calculate variance 3) multiply weekly variance by 52 • take square root • Or: 1) Compute monthly returns 2) calculate variance 3) Multiply monthly variance by 12 4) take square root
Calibrating Binomial Tree: • 1) Set “up” and “down” factors to reflect volatility: • U = 1 + s√T • D = 1 - s√T • Adjust so expected future price is forward price: • E[S(T)] = S0 ( 1 + (r – d)T ) • Simple form: • U = 1 + (r – d)T + s√T • D = 1 + (r – d)T - s√T • Or, in continuous time (McDonald): • U = exp((r – d)T + s√T) • D = exp((r – d)T - s√T) • See “Fin30233-F2017_Binomial Tutor.xls” (available on Mann’s course website)
VBA code for binomial European Call (for later reference) Function Binom(n, X) Binom = Application.Combin(n, X) * 0.5 ^ X * 0.5 ^ (n - X) End Function Function scm_bin_eur_call(S, X, rf, sigma, t, n) dt = t / n up = Exp((rf - (sigma ^ 2) / 2) * dt + sigma * Sqr(dt)) down = Exp((rf - (sigma ^ 2) / 2) * dt - sigma * Sqr(dt)) r = Exp(rf * dt) p = (r - down) / (up - down) q = 1 - p scm_bin_eur_call = 0 For Index = 0 To n scm_bin_eur_call = scm_bin_eur_call + Exp(-rf * t) * Application.Combin(n, Index) * p ^ Index * q ^ (n - Index) * Application.Max((S * up ^ Index) * (down ^ (n - Index)) - X, 0) Next Index End Function Note: code in red has to be on one line for vba to compile the code
Asset pays no dividends European call No taxes or transaction costs Constant interest rate over option life Lognormal returns: ln(1+r ) ~ N (m , s) reflect limited liability -100% is lowest possible stable return variance over option life Black-Scholes-Merton model assumptions
Simulated lognormal returns Lognormal simulation: visual basic subroutine : logreturns
Simulated lognormally distributed asset prices Lognormal price simulation: visual basic subroutine : lognormalprice)
C = S N(d1 ) - KZ(0,T) N(d2 ) ln (S/K) + (r + s2/2 )T Black-Scholes-Merton Model d1 = sT d2 = d1 -sT N( x) = Standard Normal [~N(0,1)] Cumulative density function: N(x) = area under curve left of x; e.g., N(0) = .5 coding: (excel)N(x) = NormSdist(x) N(d1 ) = Call Delta (D) = call hedge ratio = change in call value for small changein asset value = slope of call: first derivative of call with respect to asset price
s= annualized standard deviation of asset rate of return, or volatility. Implied volatility (implied standard deviation) Use observed option prices to “back out” the volatility implied by the price. Trial and error method: 1) choose initial volatility, e.g. 25%. 2) use initial volatility to generate model (theoretical) value 3) compare theoretical value with observed (market) price. 4) if: model value> market price, chooselower volatility, go to 2) model value < market price, choose higher volatility, go to 2) eventually, if model value market price, volatility is the implied volatility
VBA Code for Black-Scholes-Merton functions (no dividends) Function scm_d1(S, X, t, r, sigma) scm_d1 = (Log(S / X) + r * t) / (sigma * Sqr(t)) + 0.5 * sigma * Sqr(t) End Function Function scm_BS_call(S, X, t, r, sigma) scm_BS_call = S * Application.NormSDist(scm_d1(S, X, t, r, sigma)) - X * Exp(-r * t) * Application.NormSDist(scm_d1(S, X, t, r, sigma) - sigma * Sqr(t)) End Function Function scm_BS_put(S, X, t, r, sigma) scm_BS_put = scm_BS_call(S, X, t, r, sigma) + X * Exp(-r * t) - S End Function VBA code for implied volatility: Function scm_BS_call_ISD(S, X, t, r, C) high = 1 low = 0 Do While (high - low) > 0.0001 If scm_BS_call(S, X, t, r, (high + low) / 2) > C Then high = (high + low) / 2 Else: low = (high + low) / 2 End If Loop scm_BS_call_ISD = (high + low) / 2 End Function To enter code: tools/macro/visual basic editor at editor: insert/module type code, then compile by: debug/compile VBAproject
Call Theta: Time decay