Control of seed
Closed this issue · 2 comments
mhesselbarth commented
Thank you very much for providing these very useful distributions! Great library.
I was wondering how the seed is controlled and if there is a way to do something similar like this using RcppDist
std::mt19937 generator(seed);
std::uniform_real_distribution<double> distribution(min, max);
double x = distribution(generator);
rstub commented
RcppDist uses R's build-in RNG. So you will have to use set.seed()
on the R side.
mhesselbarth commented
Thank you, that helps!