rTrade {RMOPI} | R Documentation |
Simulate stock trade data
Description
Simulate stock trade data with assumption that the stock price following Geometric Brownian Motion (GBM).
Usage
rTrade(time, start = 100, mu = 1e-04, sigma = 2e-04)
Arguments
time |
time vector of time, must be a "Date" type variable |
start |
the start position |
mu |
the |
sigma |
the |
Value
Stock trade data with Open, High, Low and Close
Examples
date <- as.Date("2015-01-01") + days(0:29)
rTrade(date)
[Package RMOPI version 1.1 Index]