[Rcpp-devel] A beginners guide to Rcpp

Gabor Grothendieck ggrothendieck at gmail.com
Thu Nov 29 16:24:32 CET 2012


On Thu, Nov 29, 2012 at 8:34 AM, Hadley Wickham <h.wickham at gmail.com> wrote:
>> I've printed this out and will sit down with it sometime in the next week.
>> One (personal opinion) edit -- the following:
>>
>> " It is possible to write high performance code in C or Fortran. This
>> might produce faster code than C++ (but probably not), but it will
>> take you much much longer to write. Without Rcpp, you must sacrifice
>> many helpful wrappers and master the complex C internals of R
>> yourself. Rcpp is currently the best balance between speed and
>> convenience, and any other approach will be much more painful."
>>
>> should read more like:
>>
>> " It is possible but painful to write C or Fortran code for use by R.
>> Rcpp greatly simplifies this process without sacrificing speed or
>> low-level control."
>
> Thanks Christian.  I didn't really like those sentences either.  I've
> changed them to:
>
> It is _possible_ to write C or Fortran code for use in R, but it will
> be painful; Rcpp provides a clean, approachable API that lets you
> write high-performance code, insulated from R's arcane C API.
>

Nice document but it would be good to distinguish between the C
interfaces -- the .C interface may not be fully general; however, it
is adequate for a lot of numerical work such as writing the objective
function and gradient in optimization routines and is not painful at
all.

--
Statistics & Software Consulting
GKX Group, GKX Associates Inc.
tel: 1-877-GKX-GROUP
email: ggrothendieck at gmail.com


More information about the Rcpp-devel mailing list