Skip to main content

stable_random

Function stable_random 

Source
pub fn stable_random(alpha: f64, rng: &mut Rng) -> f64
Expand description

Generate a random variate from a symmetric alpha-stable distribution using the Chambers-Mallows-Stuck (CMS) algorithm.

  • alpha - stability parameter in (0, 2]. alpha=2 is Gaussian, alpha=1 is Cauchy.
  • rng - random number generator

Returns a sample from S(alpha, 0, 1, 0) (symmetric, unit scale).