powered by
Computes the price and Greeks of European call and put options using the Generalized Black-Scholes model.
GBSOption(S, X, T2M, r, b, sigma, type = "call")
A list containing the following elements:
price: The price of the option.
price
delta: The sensitivity of the option's price to a change in the price of the underlying asset.
delta
gamma: The rate of change in the delta with respect to changes in the underlying price.
gamma
vega: The sensitivity of the option's price to the volatility of the underlying asset.
vega
theta: The sensitivity of the option's price to the passage of time.
theta
rho: The sensitivity of the option's price to the interest rate.
rho
numeric, the current stock price (also known as the underlying asset price).
numeric, the strike price of the option.
numeric, the time to maturity (in years). Previously denoted as T.
numeric, the risk-free interest rate (annualized).
numeric, the cost of carry, b = r - q for dividend paying assets, where q is the dividend yield rate.
numeric, the volatility of the underlying asset (annualized).
character, the type of option to evaluate, either "call" or "put". Default is "call".
GBSOption(S = 100, X = 100, T2M = 1, r = 0.05, b = 0.02, sigma = 0.2, type = "call")
Run the code above in your browser using DataLab