Simulate from the distribution's own seeded Mersenne Twister stream. A given seed
reproduces the same draws bit-for-bit in R, Python, and the upstream C# library.
method = "latin_hypercube" draws a Latin hypercube sample instead of ordinary Monte Carlo
and is available for "MultivariateNormal" and "MultivariateStudentT" only; it requires an
explicit seed (there is no clock-seeded LHS upstream).
Usage
mvdist_random(mv, n, seed = NULL, method = c("random", "latin_hypercube"))Examples
mvdist_random(mvdist_normal(c(0, 0), diag(2)), 5, seed = 12345)
#> [,1] [,2]
#> [1,] 1.4729377 1.22735132
#> [2,] -0.4778582 -1.12305394
#> [3,] -0.9005312 -1.75348383
#> [4,] -0.8254422 0.94017513
#> [5,] 0.1705852 0.08049425