Hi Youssef, Rcpp has sugar for the R random number generators. This is nice if you want to let your users set the random seed in R code outside of the package for reproducibility: http://gallery.rcpp.org/articles/random-number-generation/
Alternatively, if you enable C++11, there are some random number generators in std: https://www.guyrutenberg.com/2014/05/03/c-mt19937-example/ Best, -- Hao Ye On Wed, Feb 7, 2018 at 10:20 AM, Hmamouche Youssef < hmamoucheyus...@gmail.com> wrote: > Hi, > > I get a note from R CMD check for an Rcpp package: > > Found ‘_srand’, possibly from ‘srand’ > > Found no calls to: ‘R_registerRoutines’, ‘R_useDynamicSymbols’ > > > Is there some an equivalent function for srand from Rcpp, which i can > use it inside c++ code? > > Best regards, > Youssef > > _______________________________________________ > Rcpp-devel mailing list > Rcpp-devel@lists.r-forge.r-project.org > https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel >
_______________________________________________ Rcpp-devel mailing list Rcpp-devel@lists.r-forge.r-project.org https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel