Skip to content

[Rcpp-devel] Sample function(s) for inclusion in RcppArmadillo

4 messages · Christian Gunning, Dirk Eddelbuettel, Jonathan Olmsted

#
Dirk,

See attached for minor edits related to Walker Alias method.  Based on
the timing tests from the gallery draft and discussion with Johnathan,
we decided it was a bad idea to include code that deviates from R's
behavior, and is slower than R to boot.  Thus, the C++ sample now
throws an informative error under the appropriate conditions.  I
updated the unitTests accordingly (and cleaned them up a bit).

Incidentally, there's now a stub in place for Walker Alias method
sample function, as well as an associated unitTest that's now
commented out.
-Christian
-------------- next part --------------
A non-text attachment was scrubbed...
Name: walker.throw.diff
Type: application/octet-stream
Size: 4455 bytes
Desc: not available
URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20130328/aa256cde/attachment.obj>
#
Yup. Progress was waiting on finalizing behavior of sample().

Current status is visible here:
https://github.com/olmjo/rcpp-gallery/blob/gh-pages/src/2013-03-19-using-the-Rcpp-based-sample-implementation.Rmd

-Jonathan


-------------------------------------------------------------------------
J.P. Olmsted

130 Corwin Hall
Politics Department
Princeton University
Princeton, NJ 08544


t: 609.258.6202
f: 609.258.1110
jolmsted at princeton.edu
http://about.me/olmjo
-------------------------------------------------------------------------
On Fri, Mar 29, 2013 at 9:38 AM, Dirk Eddelbuettel <edd at debian.org> wrote:

            
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20130329/22e8b460/attachment.html>
#
On 29 March 2013 at 18:43, Jonathan Olmsted wrote:
| Yup. Progress was waiting on finalizing behavior of sample().
| 
| Current status is visible here:?https://github.com/olmjo/rcpp-gallery/blob/
| gh-pages/src/2013-03-19-using-the-Rcpp-based-sample-implementation.Rmd

Awesome :) 

Will check this later unless I forget.

Dirk