f(x) = exp(-|x - loc|/scale) / (2 scale).
Density, distribution function, quantile and draws by inversion of the
morie Philox uniforms (identical in the Python arm).
Usage
LaplaceDist(x = NULL, loc = 0, scale = 1, p = NULL, n = 0, seed = 0)
Arguments
- x
Evaluation points.
- loc
Parameter.
- scale
Parameter.
- p
Probabilities for the quantile function.
- n
Number of random draws.
- seed
Philox seed.
Value
list(pdf, logpdf, cdf, quantile, random).
References
Johnson, N. L., Kotz, S. & Balakrishnan, N. (1995). Continuous Univariate Distributions, Vol. 2, ch. 24.
Examples
LaplaceDist(0.5)$cdf
#> [1] 0.6967347