No BSD License  

Highlights from
Matlab-GUI equity derivative calculator

image thumbnail

Matlab-GUI equity derivative calculator

by

 

24 May 2007 (Updated )

equity derivative calculator using matlab GUI

[call,put]=GeometricAsia(S,k,r,T,sigma,d)
function [call,put]=GeometricAsia(S,k,r,T,sigma,d)
%S: price of stock; d: dividend rate;
%T: time to maturity; 

%h=1/250; %day interval
%n=T/h;
%uG=log(S)+(r-d-sigma^2/2)*(T+h)/2;
%vG=sigma^2*h*(2*n+1)*(n+1)/(6*n);
%d1=(uG-log(k)+vG)/(sqrt(vG));
%d2=d1-sqrt(vG);
%call=exp(-r*T)*(exp(uG+vG/2)*normcdf(d1)-k*normcdf(d2));
%put=exp(-r*T)*(k*normcdf(-d2)-exp(uG+vG/2)*normcdf(-d1));

dA=(r+d+sigma^2/6)/2;
 vA=sigma/sqrt(3);
 [call,put]=blsprice(S,k,r,T,vA,dA);

Contact us