Compute the Greeks for both a call and a put option in a Black and Scholes model. "Delta" is the derivative of the option price with respect to the price of the underlying asset. "Gamma" is the second derivative of the option price with respect to the price of the underlying asset. "Theta" is the derivative of the option price with respect to the time to maturity. "Rho" is the derivative of the option price with respect to the riskless interest rate. "Vega" is the derivative of the option price with respect to the volatility of the underlying (log-) return.
[delta,gamma,theta,rho,vega]=bsgreeks(S,K,r,T,sigma);
Function which computes the Greeks of both call and put option in a Black and Scholes framework
current price of the underlying asset
strike price of the option
vector containing the first derivative of the call (first term) and put (second term) option prices with respect to the underlying asset price
We compute the Greeks on both a call and put option with: underlying price 25 euros, strike price 25 euros, 0.001 (annual) riskless interest rate, 3 month time to maturity (i.e. T=3/12), and 0.2 (annual) volatility.
-->[D,G,Th,R,V]=bsgreeks(25,25,0.01,3/12,0.2)
V = 4.9727729
R = 3.0550246
- 3.1793699
Th = 2.1113101
1.8619344
G = 4.9727729
D = 0.5298926
- 0.4701074
Francesco Menoncin - Brescia University - 2010