rinruby | Ruby library that integrates the R interpreter
kandi X-RAY | rinruby Summary
kandi X-RAY | rinruby Summary
RinRuby is a Ruby library that integrates the R interpreter in Ruby, making R's statistical routines and graphics available within Ruby. The library consists of a single Ruby script that is simple to install and does not require any special compilation or installation of R. Since the library is 100% pure Ruby, it works on a variety of operating systems, Ruby implementations, and versions of R. RinRuby's methods are simple, making for readable code. The website rinruby.ddahl.org describes RinRuby usage, provides comprehensive documentation, gives several examples, and discusses RinRuby's implementation. Copyright 2005-2008 David B. Dahl. Developed by David B. Dahl. Documented by David B. Dahl and Scott Crawford.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of rinruby
rinruby Key Features
rinruby Examples and Code Snippets
Community Discussions
Trending Discussions on rinruby
QUESTION
I'm trying to deploy an app to heroku. When I have gem 'rootapp-rinruby'
in the gemfile, it deploys fine, but when I use gem 'rinruby'
instead, the output below occurs.
I have been trying a number of things to debug including:
- Setting
config.assets.compile = true
inproduction.rb
, and also doing it via the method suggested here - Running
bundle exec rake -P
(see output in second code snippet below) - Updating gems
I am really stuck.
I do notice ruby/2.5.0
appearing frequently in the error messages below, which makes me suspicious, because ruby -v
returns ruby 2.5.1p57 (2018-03-29 revision 63029) [x86_64-darwin17]
and I have ruby '2.5.1'
in the gemfile. But that may have nothing to do with it
ANSWER
Answered 2019-Feb-26 at 16:20When Rails requires the rinruby gem, it will call RinRuby.new
(see here) which will eventually try to run the R
command, see here. The error doesn't raise when using the rootapp-rinruby gem as RinRuby.new
is not called when the gem/file is required.
However, a similar error will raise when using the rootapp-rinruby gem and calling RinRuby.new
.
The solution to this is to install the R library on Heroku. I recommend checking out how to install it. Some quick Google results:
- https://medium.com/@DaveQuartey/how-i-installed-r-on-heroku-ff8286233d2c
- https://elements.heroku.com/buildpacks/dpmccabe/heroku-buildpack-r
- https://www.r-bloggers.com/running-an-r-script-on-heroku/
For rinruby
, you must also make sure the heroku R buildpack is installed before the Ruby/bundler buildpack
QUESTION
I have a text file(output of my other function), need to display through ajax call. well, it is displaying the content but not the way it is. my text file is well formatted. here is a glimpse of my code, any help will be appreciated
Controller:
...ANSWER
Answered 2018-Apr-17 at 14:53You need to convert plain text to html to get the desired output. Just replace the special characters with line-break tags.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install rinruby
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page