From edd @end|ng |rom deb|@n@org  Mon Oct 14 01:43:47 2024
From: edd @end|ng |rom deb|@n@org (Dirk Eddelbuettel)
Date: Sun, 13 Oct 2024 18:43:47 -0500
Subject: [Rd] Embedding R in other applications as a scripting language
In-Reply-To: <3F34F6EC-874E-4D2E-AEFD-8736F4D282EC@R-project.org>
References: <CADPqqnKJ0js9cu2wBcAdXdJafJN1B308GHCh9rEMVmr_OkSYxA@mail.gmail.com>
 <3F34F6EC-874E-4D2E-AEFD-8736F4D282EC@R-project.org>
Message-ID: <26380.23347.901412.557101@rob.eddelbuettel.com>


Hi Bryce,

On 14 October 2024 at 09:13, Simon Urbanek wrote:
| If you are willing to use C++ then RInside is a nice package that wraps the R API in C++ classes for easier use: https://github.com/eddelbuettel/rinside simplifying it quite a bit.

Thanks for mention, Simon! And yes, embedding R is remarkably stable. Simon's
own rServe and rJava were early, and still provide a reference. There was
also (decades ago !) the embedding of R inside Postgres by Joe Conway. Jeff
later did RApache, this lead to littler on which I leaned for RInside.

Now, RInside may be of interest for two or three reason. First, it uses C++
and therefore abstract a few things (including the initialization) away into
an easy to use C++ class. Second, by being in C++ it can take advantage of
the templated converters to/from basic C/C++ types and class to R and back
making the use easier. Lastly, there are a number of examples included in the
source repo below inst/examples/ in seven different directories:
  https://github.com/eddelbuettel/rinside/tree/master/inst/examples

Hope this helps,  Dirk

-- 
dirk.eddelbuettel.com | @eddelbuettel | edd at debian.org



[Rd] Embedding R in other applications as a scripting language
Dirk Eddelbuettel