Reproducible random draws
draws.Rdn draws from stream stream of the generator keyed by seed. The same
(seed, stream) gives the same draws in R, Python and Rust.
Arguments
- dist
A distribution.
- n
Number of draws.
- seed
Generator seed: a non-negative whole number below 2^53.
- stream
Stream id; distinct streams are independent.
- ...
Unused; for methods.
Examples
draws(lognormal(0, 1), 3, seed = 42, stream = 3)
#> [1] 1.000776 1.629387 1.076387