[Rcpp-devel] Applying R functions in a cpp method
Sergio Bra
sergio.bra88 at gmail.com
Mon Apr 2 11:18:24 CEST 2018
Thank you very much!! I didn't find that part reviewing the documentation
2018-04-02 11:10 GMT+02:00 Iñaki Úcar <i.ucar86 at gmail.com>:
> 2018-04-02 11:03 GMT+02:00 Sergio Bra <sergio.bra88 at gmail.com>:
> > Hi everybody,
> >
> > I want to define a cpp function which has as input an R function, which
> is
> > applied to some internal data of my cpp code (st similar to the map
> function
> > of the purrr package). An example could be:
> >
> > my_rcpp_function("mean")
> >
> > Internally, I'd have a cpp function which applies that R function to some
> > private data (not visible from the R-side).
> >
> > My question is if Rcpp provides a way to execute an R function from cpp
> code
> > or if my issue is out of the scope of Rcpp and I'd limit to return the
> data
> > and apply the R function on the R-side.
>
> See, e.g., http://gallery.rcpp.org/articles/r-function-from-c++/
>
> Iñaki
>
> >
> > Thanks in advance.
> >
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.r-forge.r-project.org/pipermail/rcpp-devel/attachments/20180402/72d1fc37/attachment.html>
More information about the Rcpp-devel
mailing list