Closed luismarques closed 6 years ago
Another one Mir Random user is detected. ExponentialVariable is correct (at least it is not a bug). It accepts scale parameter, which is inverse of lambda. https://run.dlang.io/is/nmRSSx
@9il Not a bug, but the documentation still needs improvement. It just has a link to wikipedia, which emphasizes lambdas. Many users might be confused by this. It should at least say somewhere that scale is the inverse of lambda. This is not unique to the exponential distribution.
@9il Not a bug, but the documentation still needs improvement. It just has a link to wikipedia, which emphasizes lambdas. Many users might be confused by this. It should at least say somewhere that scale is the inverse of lambda. This is not unique to the exponential distribution.
Agreed
Maybe, I'm doing something wrong (help would be appreciated) but I'm getting nonsensical results when using an ExponentialVariable (EV).
Take an EV with lambda 0.5. We can confirm that it has a median of around 1.38629: http://www.wolframalpha.com/input/?i=median+of+exponential+distribution+with+lambda+0.5.
Therefore, I would expect that a ExponentialVariable!double(0.5) range would return approximately half of its values < 1.38629, and half > 1.38629. That doesn't seem to be the case.
(I used an explicit loop, instead of ranges, just to be sure I wasn't doing something unexpected).
Running this (https://run.dlang.io/is/r1p4vE) I get about 95% of values are smaller than the median.