Stochasta::Portfolio::GBM
Class methods
simulate_path(s0 : Float64, mu : Float64, sigma : Float64, t : Float64 = 1.0, steps : Int32 = 252) : Array(Float64)
Simulates a single price path using Geometric Brownian Motion Params:
- s0: initial price
- mu: expected annual drift
- sigma: annual volatility
- t: total time in years (e.g. 1.0)
- steps: number of time steps Returns an Array(Float64) representing the price path of size steps + 1