G
Guybrush Threepwood
Hello, trying for no particular reason to create a K constant calculator
for chemical equilibrium for a chemical reaction. The way the experiment
was done, I need to put a best fit line on some data. R, and therefore,
RSRuby, seems like the best to do this (if I'm wrong, please enlighten),
but I cannot get RSRuby working. I'm using R 2.8.1 (I found something
which said R 2.9.x doesn't work well with rsruby, not sure on the
validity of that, but, whatever), Mac OS X 10.4.11, and what happens is
the following.
I unpack the R package, and it goes into /Library/Frameworks/
I downloaded the rsruby distro, and try to run setup as ruby setup.rb
config -- -with-R-dir=$R_HOME (regardless of whether I set R_HOME to the
right directory (the installer thing says the right one is
/Library/Frameworks/r.something/Resources) or whether I put that in for
dir= it fails) and I get an error message, as it says it cannot find the
R directory. The README gives three solutions. The first, to put
something in the .bashrc file in ~ doesn't work as I don't have a
bashrc file (must say OSX isn't my forte, don't know if that is in an
earlier/later OSX distro). The second is to link a file in the
/Library/Frameworks/etcetera... to /usr/lib/, which when done, does
nothing. The last also deals with a file that I don't see anywhere.
Point is, anyone know a) what I'm doing wrong or (preferably) b) an
easier way to do this?
P.S. Here is the output
/rsruby-0.5 root# ruby setup.rb config -- --with-R-dir=$R_HOME
---> lib
---> lib/rsruby
<--- lib/rsruby
<--- lib
---> ext
/usr/bin/ruby /rsruby-0.5/ext/extconf.rb
--with-R-dir=/Library/Frameworks/R.framework/Resources/
checking for main() in -lR... no
ERROR: Cannot find the R library, aborting.
setup.rb:655:in `command': system("/usr/bin/ruby"
"/rsruby-0.5/ext/extconf.rb"
"--with-R-dir=/Library/Frameworks/R.framework/Resources/") failed
(RuntimeError)
from setup.rb:660:in `ruby'
from setup.rb:1238:in `extconf'
from setup.rb:1230:in `config_dir_ext'
from setup.rb:1532:in `__send__'
from setup.rb:1532:in `traverse'
from setup.rb:1530:in `dive_into'
from setup.rb:1530:in `traverse'
from setup.rb:1524:in `exec_task_traverse'
from setup.rb:1519:in `each'
from setup.rb:1519:in `exec_task_traverse'
from setup.rb:1223:in `exec_config'
from setup.rb:991:in `exec_config'
from setup.rb:826:in `__send__'
from setup.rb:826:in `invoke'
from setup.rb:773:in `invoke'
from setup.rb:1578
for chemical equilibrium for a chemical reaction. The way the experiment
was done, I need to put a best fit line on some data. R, and therefore,
RSRuby, seems like the best to do this (if I'm wrong, please enlighten),
but I cannot get RSRuby working. I'm using R 2.8.1 (I found something
which said R 2.9.x doesn't work well with rsruby, not sure on the
validity of that, but, whatever), Mac OS X 10.4.11, and what happens is
the following.
I unpack the R package, and it goes into /Library/Frameworks/
I downloaded the rsruby distro, and try to run setup as ruby setup.rb
config -- -with-R-dir=$R_HOME (regardless of whether I set R_HOME to the
right directory (the installer thing says the right one is
/Library/Frameworks/r.something/Resources) or whether I put that in for
dir= it fails) and I get an error message, as it says it cannot find the
R directory. The README gives three solutions. The first, to put
something in the .bashrc file in ~ doesn't work as I don't have a
bashrc file (must say OSX isn't my forte, don't know if that is in an
earlier/later OSX distro). The second is to link a file in the
/Library/Frameworks/etcetera... to /usr/lib/, which when done, does
nothing. The last also deals with a file that I don't see anywhere.
Point is, anyone know a) what I'm doing wrong or (preferably) b) an
easier way to do this?
P.S. Here is the output
/rsruby-0.5 root# ruby setup.rb config -- --with-R-dir=$R_HOME
---> lib
---> lib/rsruby
<--- lib/rsruby
<--- lib
---> ext
/usr/bin/ruby /rsruby-0.5/ext/extconf.rb
--with-R-dir=/Library/Frameworks/R.framework/Resources/
checking for main() in -lR... no
ERROR: Cannot find the R library, aborting.
setup.rb:655:in `command': system("/usr/bin/ruby"
"/rsruby-0.5/ext/extconf.rb"
"--with-R-dir=/Library/Frameworks/R.framework/Resources/") failed
(RuntimeError)
from setup.rb:660:in `ruby'
from setup.rb:1238:in `extconf'
from setup.rb:1230:in `config_dir_ext'
from setup.rb:1532:in `__send__'
from setup.rb:1532:in `traverse'
from setup.rb:1530:in `dive_into'
from setup.rb:1530:in `traverse'
from setup.rb:1524:in `exec_task_traverse'
from setup.rb:1519:in `each'
from setup.rb:1519:in `exec_task_traverse'
from setup.rb:1223:in `exec_config'
from setup.rb:991:in `exec_config'
from setup.rb:826:in `__send__'
from setup.rb:826:in `invoke'
from setup.rb:773:in `invoke'
from setup.rb:1578