rBM | R Documentation |
Simulate a sample path of Brownian motion
rBM(times, sigma = 1, B0 = 0, u = 0)
times |
numeric vector of time points where the Brownian motion should be simulated |
sigma |
numeric scalar, noise level in the Brownian motion, defaults to 1 |
B0 |
numeric scalar, initial condition (at time=0) for the Brownian motion |
u |
numeric scalar, drift |
numeric vector, of same length as times, containing the simulated value of the Brownian motion
rvBM
for a vectorized version
times <- 0:10
plot(times,rBM(times),type="b",xlab="Time",ylab="Brownian motion")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.