I have a rails app that is hosted on Heroku for which I want to incorporate some live data analysis. Ideally, I'd love to figure out a way to run a generalized boosted regression model, which I know is available in both R (http://cran.r-project.org/web/packages/gbm/index.html) and Stata (http://www.stata-journal.com/article.html?article=st0087). I want to save the resulting gbm tree and then, within my app, use it to predict new results based on user input.
If that's not possible, I'd be open to using other data mining algorithms. Most important to me is the ability to integrate it into my Heroku app so that it can run without my local machine.
Options I've looked into:
1) Heroku Support suggested vendoring the R library into a ruby gem. I'm relatively new to ruby and rails, is this something that would be feasible for me to do. I've looked around for instructions on vendoring libraries in gems, but haven't been able to find much.
2) Another thread here (https://mcmap.net/q/1623446/-statistic-engine-that-work-with-heroku) mentioned CloudNumbers, but it doesn't seem possible to call the service from a Rails app.
3) In one of their case studies, Heroku mentions FlightCaster, which uses Clojure, Hadoop, and EC2 for their machine learning (http://www.infoq.com/articles/flightcaster-clojure-rails). I saw that Heroku supports Clojure, but is there a way to integrate it (or more specifically Incanter) into my Rails app?
Please let me know if you have any ideas.