Generate Data From Stable Distributions
Generate data from stable distribution with infinite variance.
rStable(n, Alpha, Beta, Scale = NULL, Location = NULL)
n |
length of the series. |
Alpha |
index stability parameters, each in the range |
Beta |
skewness parameters, each in the range |
Scale |
scale parameters. |
Location |
location parameters. |
Alpha, Beta, Scale,
and Location
should have the same length.
This length, k, represents the number of the variables that we need to generate.
The code in the function rStable
extends that one given
in the package fBasics
to the multivariate case.
Many thanks to Diethelm Wuertz for putting his code under the GPL
license.
A vector of dimension n\times k from independent stable distributions.
Esam Mahdi and A.I. McLeod.
Chambers, J.M., Mallows, C.L., and Stuck, B.W. (1976). "A Method for Simulating Stable Random Variables". Journal of American Statistical Association, 71, 340-344.
Wuertz, D., core team members R (2014). "fBasics: Rmetrics - Markets and Basic Statistics".
R
package version 3011.87. https://CRAN.R-project.org/package=fBasics
There is also a function rstable
in the fBasics
package for the univariate case only.
See also fitstable
, varima.sim
## Generate Univariate Data n <- 500 Alpha <- 1.75 Beta <- 0 Scale <- 1.5 Location <- 0 rStable(n, Alpha, Beta, Scale, Location) ## Generate Bivariate Data n <- 500 Alpha <- c(1.3,1.5) Beta <- c(0.3,-0.6) rStable(n, Alpha, Beta) ## Generate Multivariate Data n <- 500 Alpha <- c(1.3,1.5,1.7) Beta <- c(0.3,-0.6,0) Scale <- c(3,1,6) rStable(n, Alpha, Beta,Scale)
Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.