[Rcpp-devel] problem with sample() implemented in Rcpp/RcppArmadillo
Update -- I've implemented all of R's sample (with identical results) except for the walker alias method. I used Armadillo for ProbSampleReplace and ProbSampleNoReplace, since there's no good STL replacement for R's revsort.
Out of curiosity, what does revsort do? It must be something beyond just a reverse-order sort? Darren P.S. I don't have an R function of that name. Googling found it used in random.c but not where its defined!