visualize: Option Parameter Visualization

Description Usage Arguments Value Examples

View source: R/visualize.R

Description

Creates a 3D Plot of an Option Parameter plotted over time

Usage

1
2
3
4
5
6
7
visualize(type = "call", parameter = "premium", s = 100, si = 100,
  x1 = 90, x2 = 95, x3 = 105, x4 = 110, v1 = 0.2, v2 = v1,
  v3 = v1, v4 = v1, ti = 45/365, r = 0.02, d = 0, ls = 1,
  low = 75, high = 125, e1 = (0), e2 = (5/365), e3 = (10/365),
  e4 = (15/365), e5 = (20/365), e6 = (25/365), e7 = (30/365),
  e8 = (35/365), e9 = (40/365), e10 = (45/365), c1 = 1, c2 = 1,
  c3 = 1, c4 = 1)

Arguments

type

Character String: "call" or "put"

parameter

Character String: "premium", "delta", "gamma", "vega", "theta", "rho"

s

Underlying Asset Price

si

Initial Price of the underlying asset

x1

Option 1 Strike

x2

Option 2 Strike

x3

Option 3 Strike

x4

Option 4 Strike

v1

Option 1 Volatility

v2

Option 2 Volatility

v3

Option 3 Volatility

v4

Option 4 Volatility

ti

Initial time to maturity in years

r

Annualized continuously compounded risk-free rate

d

Annualized continuously compounded dividend yield

ls

Numerical either 1 or -1

low

Lower Limit for the price range

high

Upper Limit for the price range

e1

Expiration in years, set to 0

e2

Expiration in years, set to 5/365

e3

Expiration in years, set to 10/365

e4

Expiration in years, set to 15/365

e5

Expiration in years, set to 20/365

e6

Expiration in years, set to 25/365

e7

Expiration in years, set to 30/365

e8

Expiration in years, set to 35/365

e9

Expiration in years, set to 40/365

e10

Expiration in years, set to 45/365

c1

Option 1, Number of Contracts

c2

Option 2, Number of Contracts

c3

Option 3, Number of Contracts

c4

Option 4, Number of Contracts

Value

Plots a 3d Graph in the Viewer tab

Examples

1
2
3
4
5
visualize(type = "put", parameter = "delta", s = 100, si = 100,
    x1 = 90, x2 = 95, x3 = 105, x4 = 110, v1 = 0.20,
    ti = 45/365, r = 0.02, d = 0, ls = 1,
    low = 75, high = 125, e1 =(45/365), e2 = (30/365),
    e3 = (15/365), e4 = (1/365), c1 = 1, c2 = 1, c3 = 1, c4 = 1)

visualR documentation built on Aug. 21, 2019, 1:05 a.m.