I did my time with rsruby, rinruby and Rserve-Ruby-client. In retrospect I should have trusted the Rserve-Ruby-client readme which details the problems with rsruby and rinruby.
- rsruby – dealbreaker is that this is not stable, there are a few other downsides including complex data conversions and compilation issues but enough said.
- rinruby – slow, but more importantly fails when assigning large data making it pretty much useless. See Bug #2 and Bug #13.
Solution: use Rserve and Rserve-Ruby-client. Both are actively maintained and stable.
Rserver can be installed on Debian/Ubuntu with:
apt-get install r-cran-rserve
Be aware that there is a bug in the Ubuntu package that requires fixing for rserve to work:
If you are interested, could you take a look at SciCom… it is another Gem that integrates R with Ruby, but it does so using Renjin, an R interpreter for the JVM. At this point Renjin supports all of R but not all packages, in particular, Renjin and SciCom do not yet support any graphics. I have a comparison of SciCom and S4 in: https://github.com/rbotafogo/scicom/wiki/A-(not-so)-Short-Introduction-to-SciCom.