simGBM: GBM process simulation

View source: R/simGBM.R

simGBMR Documentation

GBM process simulation

Description

Simulates a Geometric Brownian Motion process

Usage

simGBM(
  nsims = 1,
  S0 = 10,
  drift = 0,
  sigma = 0.2,
  T2M = 1,
  dt = 1/12,
  vec = TRUE
)

Arguments

nsims

number of simulations. Defaults to 1

S0

Spot price at t=0

drift

Drift term in percentage

sigma

Standard deviation

T2M

Maturity in years

dt

Time step in period e.g. 1/250 = 1 business day.

vec

Vectorized implementation. Defaults to TRUE

Value

A tibble of simulated values

Author(s)

Philippe Cote

Examples

simGBM(nsims = 2, S0 = 10, drift = 0, sigma = 0.2, T2M = 1, dt = 1 / 12, vec = TRUE)

RTL documentation built on June 17, 2022, 5:06 p.m.