Skip to content

black_scholes_73

module jetblack_options.european.black_scholes_73

Summary

Black-Scholes 1973.

Description

The original Black-Scholes option formula for an option on a non-dividend paying stock option.

d1=1σTt[ln(StK)+(r+σ22)(Tt)] d2=d1σTt

function jetblack_options.european.black_scholes_73.charm


jetblack_options.european.black_scholes_73.charm(
is_call: bool,
S: float,
K: float,
T: float,
r: float,
v: float
) -> float

Parameters

is_call: bool
S: float
K: float
T: float
r: float
v: float

Returns

float:

function jetblack_options.european.black_scholes_73.delta


jetblack_options.european.black_scholes_73.delta(
is_call: bool,
S: float,
K: float,
T: float,
r: float,
v: float
) -> float

Parameters

is_call: bool
S: float
K: float
T: float
r: float
v: float

Returns

float:

function jetblack_options.european.black_scholes_73.gamma

Summary

Calculates option gamma

jetblack_options.european.black_scholes_73.gamma(
S: float,
K: float,
T: float,
r: float,
v: float
) -> float

Parameters

S: float
K: float
T: float
r: float
v: float

Returns

float:

function jetblack_options.european.black_scholes_73.ivol

Summary

Calculate the volatility of a Black-Scholes 73 option that is implied by

Description

the price.

jetblack_options.european.black_scholes_73.ivol(
is_call: bool,
S: float,
K: float,
T: float,
r: float,
p: float,
*,
max_iterations: int, Optional,
epsilon: float, Optional
) -> float

Parameters

is_call: bool

True for a call, false for a put.

S: float

The current asset price.

K: float

The option strike price

T: float

The time to maturity of the option in years.

r: float

The risk free rate.

p: float

The option price.

max_iterations: int, Optional

The maximum number of iterations before a price is returned. Defaults to 35.

epsilon: float, Optional (optional)

The largest acceptable error. Defaults to 1e-8.

Returns

float: The implied volatility.

function jetblack_options.european.black_scholes_73.make_numeric_greeks

Summary

Make a class to generate greeks numerically using finite difference methods.

jetblack_options.european.black_scholes_73.make_numeric_greeks(
is_call: bool
) -> NumericGreeks

Parameters

is_call: bool

If true the options is a call; otherwise it is a put.

Returns

NumericGreeks: A class which can generate Greeks using finite difference methods.

function jetblack_options.european.black_scholes_73.price

Summary

Black-Scholes for a non-dividend paying stock.

Description

C(St,t)=N(d1)StN(d2)Ker(Tt)
jetblack_options.european.black_scholes_73.price(
is_call: bool,
S: float,
K: float,
T: float,
r: float,
v: float
) -> float

Parameters

is_call: bool

True for a call, false for a put.

S: float

The asset price.

K: float

The strike price.

T: float

The time to expiry in years.

r: float

The risk free rate.

v: float

The asset volatility.

Returns

float: The price of the option.

function jetblack_options.european.black_scholes_73.rho


jetblack_options.european.black_scholes_73.rho(
is_call: bool,
S: float,
K: float,
T: float,
r: float,
v: float
) -> float

Parameters

is_call: bool
S: float
K: float
T: float
r: float
v: float

Returns

float:

function jetblack_options.european.black_scholes_73.theta

Summary

Calculates option theta

jetblack_options.european.black_scholes_73.theta(
is_call: bool,
S: float,
K: float,
T: float,
r: float,
v: float
) -> float

Parameters

is_call: bool
S: float
K: float
T: float
r: float
v: float

Returns

float:

function jetblack_options.european.black_scholes_73.vanna


jetblack_options.european.black_scholes_73.vanna(
S: float,
K: float,
T: float,
r: float,
v: float
) -> float

Parameters

S: float
K: float
T: float
r: float
v: float

Returns

float:

function jetblack_options.european.black_scholes_73.vega


jetblack_options.european.black_scholes_73.vega(
S: float,
K: float,
T: float,
r: float,
v: float
) -> float

Parameters

S: float
K: float
T: float
r: float
v: float

Returns

float:

function jetblack_options.european.black_scholes_73.vomma


jetblack_options.european.black_scholes_73.vomma(
S: float,
K: float,
T: float,
r: float,
v: float
) -> float

Parameters

S: float
K: float
T: float
r: float
v: float

Returns

float: