Integrating Rserve Into A Rails Application
This question is a follow-up to a question I posted earlier this year.
Integrating R Statistical Package into Rails Application
Based upon the response I received, I have landed on Rserve as the means to integrate R into my rails application. Specifically, I will:
I'm running jruby via torque box and plan to use R with the mlogit package.
My questions are:
Thanks for your input.
To answer your questions:
Yes. I integrated rserve into a rails application. I served it successfully on my own server. I did have some issues when trying to use Heroku to serve my app (using the r buildpack). While debugging I switched to rinruby to match the examples for the buildpack.
The performance of rserve was good on my server. Rinruby also performs well.
I do not use any packages in my app. However it is easy to do so. If you are deploying to Heroku, see the init.r file in the example for the r buildpack.
For an app with little traffic, Heroku will serve the app for free. The main difference between rserve and rinruby is that with rserve you will start up your own instance of R that ruby will then communicate with. Rinruby starts its own instance of R from within ruby.
上一篇: Java获取边框颜色和大小
下一篇: 将Rserve集成到Rails应用程序中