AmericanBinary computes the value of American binary (a.k.a. digital) calls and puts.
AmericanBinary is written by Parsiad Azimzadeh and released under a BSD 2-clause license.
We assume that the asset follows a geometric Brownian motion:
dS = (Rate - Yield) dt + Volatility dW
An American binary call is an option which can be exercised at any time, having an exercise value 1 if S > Strike and exercise value 0 otherwise. An American binary put is defined similarly.
The derivation of the closed-form expression for the value of the American binary call and put are here.
[Call, Put] = AmericanBinary(Price, Strike, Rate, Time, Volatility, Yield)Price: The initial value of the asset SStrike: The strike priceRate: The risk-free interest rateTime: The expiry time (useInffor a perpetual option)Volatility: The volatility of the asset SYield: The dividend rate of the asset SCall: The value of the callPut: The value of the put
The function, similar to blsprice, accepts vector/matrix arguments.
Strike = 100.;
Price = 0 : 1 : Strike * 2;
Rate = 0.04;
Time = 1.;
Volatility = 0.2;
Yield = 0.01;
[Call, Put] = AmericanBinary(Price, Strike, Rate, Time, Volatility, Yield);
plot(Price, Put, 'linewidth', 2);
xlabel('Asset price');
ylabel('Option value');
title('American binary put');