Free Access Week - Data Engineering + BI
Data Engineering and BI courses are free this week!
Free Access Week - Jun 2-8

mixSSG (version 2.1.1)

rpstable: Simulating positive stable random variable.

Description

The cumulative distribution function of positive stable distribution is given by FP(x)=1π0πexp{xα2αa(θ)}dθ, where 0<α2 is tail thickness or index of stability and a(θ)=sin((1α2)θ)[sin(αθ2)]α2α[sin(θ)]22α. Kanter (1975) used the above integral transform to simulate positive stable random variable as P=d(a(θ)W)2αα, in which θU(0,π) and W independently follows an exponential distribution with mean unity.

Usage

rpstable(n, alpha)

Value

simulated realizations of size n from positive α-stable distribution.

Arguments

n

the number of samples required.

alpha

the tail thickness parameter.

Author

Mahdi Teimouri

References

M. Kanter, 1975. Stable densities under change of scale and total variation inequalities, Annals of Probability, 3(4), 697-707.

Examples

Run this code
 rpstable(10, alpha = 1.2) 

Run the code above in your browser using DataLab