Ticket #1416 (closed defect: fixed)
get the R statistics software into Sage
| Reported by: | was | Owned by: | was |
|---|---|---|---|
| Priority: | major | Milestone: | sage-2.9 |
| Component: | packages: standard | Keywords: | |
| Cc: | Work issues: | ||
| Report Upstream: | Reviewers: | ||
| Authors: | Merged in: | ||
| Dependencies: | Stopgaps: |
Description (last modified by was) (diff)
MUST DO
- (done) upgrade to 2.6.1
- (done) fix build issues and install issues
- (done) worry about graphics / X11 issues
- (done) readline
- (done) gfortran support (modify setup.py in rpy package; anything else?)
TODO LATER
- finish pexpect interface.
- properly patch rpy so _rpy_ methods are called.
Change History
comment:2 Changed 5 years ago by was
See this for valuable info for building on osx 10.5: http://r.research.att.com/building.html
comment:3 Changed 5 years ago by mabshoff
For the integration of R we already had #348, but this ticket had more info, I turned the other ticket into a dup and closed it.
Cheers,
Michael
comment:4 Changed 5 years ago by was
- Milestone changed from sage-2.10 to sage-2.9
Add this to spkg/install
R=`$newest r` export R
Add this to spkg/standard/deps (somewhere in the middle):
$(INST)/$(R): $(INST)/$(PYTHON)
$(SAGE_SPKG) $(R) 2>&1
$(MAKEREL)
and also add this to the big list of things the $(INST)/$(SAGE) target depends on:
$(INST)/$(R) \
WARNING: The above is untested, so probably not perfect -- though I'm pretty confident.
comment:6 Changed 5 years ago by was
- Description modified (diff)
WAIT: Readline detection still doesn't work -- i.e., only using the readline in sage -- at least on one platform, namely sagemath.org (opteron ubuntu 64bit):
0.3 -L/usr/lib/gcc -lf95 -lm ../extra/zlib/libz.a ../extra/bzip2/libbz2.a ../extra/pcre/libpcre.a -lreadline -lncurses -ldl -lm /usr/bin/ld: cannot find -lreadline collect2: ld returned 1 exit status make[3]: *** [libR.so] Error 1 make[3]: Leaving directory `/home2/sage/s/local/lib/r/src/main' make[2]: *** [R] Error 2 make[2]: Leaving directory `/home2/sage/s/local/lib/r/src/main' make[1]: *** [R] Error 1 make[1]: Leaving directory `/home2/sage/s/local/lib/r/src' make: *** [R] Error 1 Error building R. real 2m59.168s user 1m9.016s sys 0m30.386s sage: An error occurred while installing r-2.6.1.p2 Please email sage-devel http://groups.google.com/group/sage-devel explaining the problem and send the relevant part of of /home2/sage/s/install.log. Describe your computer, operating system, etc. If you want to try to fix the problem, yourself *don't* just cd to /home2/sage/s/spkg/build/r-2.6.1.p2 and type 'make'. Instead type "/home2/sage/s/sage -sh" in order to set all environment variables correctly, then cd to /home2/sage/s/spkg/build/r-2.6.1.p2 (When you are done debugging, you can type "exit" to leave the subshell.)
comment:7 Changed 5 years ago by jkantor
The r package itself appears to check versions and correctly link libf95 or libgfortran on its own. It compiled fine using gfortran. The rpy package does not do this, but the spkg in 1427 that fixes the osx 10.4 build also makes is work with g95 or gfortran. So just use that rpy package.
comment:8 Changed 5 years ago by jkantor
you may just want to grab the newest rpy from my home directory to make sure you actually got the newest one.
Josh
comment:10 Changed 5 years ago by mabshoff
- Status changed from new to closed
- Resolution set to fixed
Merged in 2.9.alpha3.

NOTE: For building on OSX I had to remove SAGE_ROOT/local/lib/libsqlite3.so