role-model / roleR

R package implementing the RoLE model
https://role-model.github.io/roleR
GNU General Public License v3.0
1 stars 2 forks source link

number number generator as member of a class #44

Open ajrominger opened 1 year ago

ajrominger commented 1 year ago

I just pushed an example of how this could work (commit 9de80849a33394fee72deb2e8bce9417de41b485). importantly, the r function set.seed does not work with using std::mt19937 from within rcpp. i left a comment on line 15 of the file scr/randExample.cpp of where setting a set can happen. if we need to set a set, we'd have to modify this line in a way where the state of the R environment (i.e. the seed there) can be passed to the mt19937 generator