Description Usage Arguments Value Author(s) Examples
Plot Custom Vertical Spread
1 2 3 |
options |
String argument, either "call" or "put" |
s |
Spot price of the underlying asset |
x1 |
Short strike (either higher or lower) |
x2 |
Long strike (either higher or lower) |
t |
Time to expiration in years |
r |
Annual continuously compounded risk-free rate |
sigma |
Annualized implied volatility of the short option |
sigma2 |
Annualized implied volatility of the long option |
d |
Annual continuously compounded dividend yield |
ll |
Lower-limit of the plot, set as (desired price/spot) |
ul |
Upper-limit of the plot, set as (desired price/spot) |
xlab |
X-Axis Label |
ylab |
Y-Axis Label |
main |
Title of the plot |
... |
Additional plot parameters |
Returns a plot of a custom vertical spread. Black line: The profit(loss) at expiration. Red line: The profit(loss) at (1/2) time "t" ~ half-way to expiration. Blue line: The profit(loss) at inception.
John T. Buynak
1 | plotvertical("call", 100, 90, 110, (45/365), 0.02, 0.20)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.