plotdv: Plot Double Vertical Spread

Description Usage Arguments Details Value Author(s) Examples

View source: R/optionstrat.R

Description

Plot a double vertical spread (credit spread)

Usage

1
2
3
plotdv(s, x1, x2, x3, x4, t, r, sigma, sigma2 = sigma, sigma3 = sigma,
  sigma4 = sigma, d = 0, ll = 0.75, ul = 1.25, xlab = "spot",
  ylab = "Profit/Loss", main = "Double Vertical Spread", ...)

Arguments

s

Spot price of the underlying asset

x1

Lower-strike put option price (long option)

x2

Higher-strike put option price (short option)

x3

Lower-strike call option price (short option)

x4

Higher-strike call option price (long option)

t

Time to expiration in years

r

Annual continuously compounded risk-free rate

sigma

Annualized implied volatility of the lower-strike put option

sigma2

Annualized implied volatility of the higher-strike put option

sigma3

Annualized implied volatility of the lower-strike call option

sigma4

Annualized implied volatility of the higher-strike call option

d

Annual continuously compounded risk-free rate

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

Details

The double vertical spread consists of a credit put spread and a credit debit spread.

Value

Returns a plot of a double vertical spread (credit 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.

Author(s)

John T. Buynak

Examples

1
plotdv(s= 100, x1 = 90, x2 = 95, x3 = 105, x4 = 110, t = (45/365), r = 0.02, sigma = 0.20)

Example output



optionstrat documentation built on Dec. 4, 2019, 1:08 a.m.