aleatory.processes.CEVProcess#

class aleatory.processes.CEVProcess(*args, **kwargs)[source]#

Constant Elasticity of Variance (CEV) process#

../_images/cev_process_drawn.png

Notes#

A CEV process \(X = \{X : t \geq 0\}\) is characterised by the following Stochastic Differential Equation

\[dX_t = \mu X_t dt + \sigma X_t^{\gamma} dW_t, \ \ \ \ \forall t\in (0,T],\]

with initial condition \(X_0 = x_0\), where

  • \(\mu\) is the drift

  • \(\sigma>0\) is the scale of the volatility

  • \(\gamma\geq 0\) is the elasticity term

  • \(W_t\) is a standard Brownian Motion.

Constructor, Methods, and Attributes#

__init__(alpha=0.5, beta=0.5, sigma=0.1, gamma=1.0, initial=1.0, T=1.0, rng=None)#
Parameters:
  • alpha (float) – the parameter \(\alpha\) in the above SDE

  • beta (float) – the parameter \(\beta\) in the above SDE

  • sigma (float) – the parameter \(\sigma>0\) in the above SDE

  • gamma (float) – the parameter \(\gamma\) in the above SDE

  • initial (float) – the initial condition \(x_0\) in the above SDE

  • T (float) – the right hand endpoint of the time interval \([0,T]\) for the process

  • rng (numpy.random.Generator) – a custom random number generator

Methods

__init__([alpha, beta, sigma, gamma, ...])

param float alpha:

the parameter \(\alpha\) in the above SDE

draw(n, N[, T, marginal, envelope, title, ...])

Simulates and plots paths/trajectories from the instanced stochastic process.

estimate_covariances([times])

estimate_expectations()

estimate_quantiles(q)

estimate_stds()

estimate_variances()

marginal_expectation([times])

marginal_stds([times])

marginal_variance([times])

plot(n, N[, T, title, suptitle])

Simulates and plots paths/trajectories from the instanced stochastic process.

plot_covariance([times, title])

plot_kernel([times, colormap, matrix_shape, ...])

plot_kernel3d([times, title])

plot_mean_variance([times, title])

plot_paths_and_kernel(n, N[, T, title, ...])

Plots the paths of the process and the covariance kernel.

process_covariance([times])

process_expectation()

process_stds()

process_variance()

sample(n)

simulate(n, N[, T])

Simulate paths/trajectories from the instanced stochastic process.

Attributes

T

End time of the process.

alpha

beta

gamma

rng

sigma