[R] problem in generating positive stable random numbers
X. Cong
xcong at stat.rice.edu
Tue Aug 30 21:26:58 CEST 2005
Dear all,
I am trying to use the
rstable(n, alpha, beta, gamma = 1, delta = 0, pm = c(0, 1, 2)))
function to generate positive stable random numbers. For positive stable
distribution, beta==1 and alpha is in (0,1), which defines random variables
with support (0, infinity). So, I used rstable(100, 0.5, 1) for an example.
I found that this gives me some negative numbers. For example,
> rstable(10, 0.5, 1)
[1] 6.3016252 399.3659030 11.2735789 1.9550625 -0.6762333 1.6810761
[7] 0.9091360 1.9100991 -0.7593737 24.2788471
Does anybody know why this should happen?
Thanks a lot,
Julie
More information about the R-help
mailing list