[R] Ubunut + Eclipse + StatET: Console terminates upon error
Dear List, I'm trying to set up Eclispe (3.5.1) with the StatET-Plugin (0.8.1) under Ubuntu (Karmic) and found it strange that my console terminates every time something in a script produces an arbitrary error (e.g. just calling a missing variable, trying to perform an illegal operation etc.). Can anyone tell me why this happens or even better how to fix this? Thanks a lot, Janko [[alternative HTML version deleted]] __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
Re: [R] Ubunut + Eclipse + StatET: Console terminates upon error
On 11 March 2010 at 19:19, Janko Thyson wrote: | I'm trying to set up Eclispe (3.5.1) with the StatET-Plugin (0.8.1) under | Ubuntu (Karmic) and found it strange that my console terminates every time | something in a script produces an arbitrary error (e.g. just calling a | missing variable, trying to perform an illegal operation etc.). Can anyone | tell me why this happens or even better how to fix this? It so happens that I help a colleague recently to triage this. The problem there was that a recent rJava was needed + and installed -- and on Ubuntu and Debian this goes into /usr/local/lib/R/site-library/ and StatET -- as shipped -- does not look there. I don't use Eclipse so I don't recall where to set this, but in essence you need to make sure that StatET looks where R puts things. And that tends to be R .libPaths() [1] /usr/local/lib/R/site-library /usr/lib/R/site-library [3] /usr/lib/R/library R CCing Tobias just in case. Dirk -- Registration is open for the 2nd International conference R / Finance 2010 See http://www.RinFinance.com for details, and see you in Chicago in April! __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
Re: [R] Ubunut + Eclipse + StatET: Console terminates upon error
Thanks for the quick reply. I was following your hint with rJava, but I'm still a little lost. I maybe should have added that the console terminating happens when launching it as Rterm, it works fine when running it as RJ. However, I would like to use Rterm. Here is what I did so far: First of, I'm still confused about Ubuntu's sudo way of doing things. Not knowing how to authorize me as root when installing packages from a R-script, I can't write on /usr/local/lib/R/site-library or /usr/lib/R/site-library. So I turned to Synaptics, found and installed the CRAN package rJava that enables me to run the R console with Launch Type RJ within Eclipse. rJava went into /usr/lib. Then, launching R as RJ and trying to execute an install.packages(), Ubuntu prompted me for the specification of a valid library directory and offered to create /home/ME/i486-pc-linux-gnu-library/2.10. So .libPaths() would give me: R .libPaths() [1] /home/ME/i486-pc-linux-gnu-library/2.10 /usr/lib/R/site-library [3] /usr/lib/R/library R I then tried to re-install the package rJava by install.packages() which got me the following output: + install.packages(rJava, repos=repos.cran, lib=/home/ME/R/i486-pc-linux-gnu-library/2.10) trying URL 'http://cran.at.r-project.org/src/contrib/rJava_0.8-2.tar.gz' Content type 'application/x-gzip' length 471971 bytes (460 Kb) opened URL == downloaded 460 Kb * installing *source* package ‘rJava’ ... checking for gcc... gcc -std=gnu99 checking for C compiler default output file name... a.out checking whether the C compiler works... yes checking whether we are cross compiling... no checking for suffix of executables... checking for suffix of object files... o checking whether we are using the GNU C compiler... yes checking whether gcc -std=gnu99 accepts -g... yes checking for gcc -std=gnu99 option to accept ISO C89... none needed checking how to run the C preprocessor... gcc -std=gnu99 -E checking for grep that handles long lines and -e... /bin/grep checking for egrep... /bin/grep -E checking for ANSI C header files... yes checking for sys/wait.h that is POSIX.1 compatible... yes checking for sys/types.h... yes checking for sys/stat.h... yes checking for stdlib.h... yes checking for string.h... yes checking for memory.h... yes checking for strings.h... yes checking for inttypes.h... yes checking for stdint.h... yes checking for unistd.h... yes checking for string.h... (cached) yes checking sys/time.h usability... yes checking sys/time.h presence... yes checking for sys/time.h... yes checking for unistd.h... (cached) yes checking for an ANSI C-conforming const... yes checking whether time.h and sys/time.h may both be included... yes configure: checking whether gcc -std=gnu99 supports static inline... yes checking whether setjmp.h is POSIX.1 compatible... yes checking whether sigsetjmp is declared... yes checking whether siglongjmp is declared... yes checking Java support in R... present: interpreter : '/usr/bin/java' archiver: '/usr/bin/jar' compiler: '/usr/bin/javac' header prep.: '/usr/bin/javah' cpp flags : '' java libs : '-L/usr/lib/jvm/java-6-openjdk/jre/lib/i386/server -L/usr/lib/jvm/java-6-openjdk/jre/lib/i386 -L/usr/lib/jvm/java-6-openjdk/jre/../lib/i386 -L -L/usr/java/packages/lib/i386 -L/usr/lib/jni -L/lib -L/usr/lib -ljvm' configure: error: One or more Java configuration variables are not set. Make sure R is configured with full Java support (including JDK). Run R CMD javareconf as root to add Java support to R. If you don't have root privileges, run R CMD javareconf -e to set all Java-related variables and then install rJava. ERROR: configuration failed for package ‘rJava’ * removing ‘/home/ME/R/i486-pc-linux-gnu-library/2.10/rJava’ The downloaded packages are in ‘/tmp/RtmpbGKuzS/downloaded_packages’ Warning message: In install.packages(rJava, repos = repos.cran, lib = /home/ME/R/i486-pc-linux-gnu-library/2.10) : installation of package 'rJava' had non-zero exit status + So I ran sudo R CMD javareconf, but still get the same error. Any hints from here on? Thanks a lot! Janko -Ursprüngliche Nachricht- Von: Dirk Eddelbuettel [mailto:e...@debian.org] Gesendet: Donnerstag, 11. März 2010 19:40 An: Janko Thyson Cc: r-help@r-project.org; tobias.verb...@openanalytics.eu Betreff: Re: [R] Ubunut + Eclipse + StatET: Console terminates upon error On 11 March 2010 at 19:19, Janko Thyson wrote: | I'm trying to set up Eclispe (3.5.1) with the StatET-Plugin (0.8.1) under | Ubuntu (Karmic) and found it strange that my console terminates every time | something in a script produces an arbitrary error (e.g. just calling a | missing variable, trying to perform an illegal operation etc.). Can anyone | tell me why this happens or even better how to fix this? It so happens that I help a colleague recently to triage this. The problem
Re: [R] Ubunut + Eclipse + StatET: Console terminates upon error
Hi Dirk, Janko, Dirk Eddelbuettel wrote: On 11 March 2010 at 19:19, Janko Thyson wrote: | I'm trying to set up Eclispe (3.5.1) with the StatET-Plugin (0.8.1) under | Ubuntu (Karmic) and found it strange that my console terminates every time | something in a script produces an arbitrary error (e.g. just calling a | missing variable, trying to perform an illegal operation etc.). Can anyone | tell me why this happens or even better how to fix this? I never experienced such behaviour and use Eclipse/StatET daily on Ubuntu Karmic. I did experience weird UI behaviour once (related to a GTK bug) and currently use this #!/bin/bash export GDK_NATIVE_WINDOWS=1 /opt/eclipse/eclipse -debug -consolelog -vmargs -Xms1024m -Xmx2048m -XX:MaxPermSize=2048m to launch eclipse (never mind the insane vmargs ;-) While we're at it: if you have the choice, you can upgrade to Eclipse 3.5.2 (i.e. Galileo SR2) and to StatET 0.8.2 (which is available via the update site at http://download.walware.de/eclipse-3.5 ) It so happens that I help a colleague recently to triage this. The problem there was that a recent rJava was needed + and installed -- and on Ubuntu and Debian this goes into /usr/local/lib/R/site-library/ and StatET -- as shipped -- does not look there. I don't use Eclipse so I don't recall where to set this, but in essence you need to make sure that StatET looks where R puts things. And that tends to be The libraries can be set (and auto-detected) when defining an R environment in the Preferences under StatET Run/Debug R Environments. The R environment for a particular R Console Run Configuration is in turn set in the R Config tab (of the named Run Configuration). R .libPaths() [1] /usr/local/lib/R/site-library /usr/lib/R/site-library [3] /usr/lib/R/library R CCing Tobias just in case. Don't hesitate if there would be further questions. There also is a dedicated StatET user list at https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/statet-user HTH, Tobias __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
Re: [R] Ubunut + Eclipse + StatET: Console terminates upon error
: Re: [R] Ubunut + Eclipse + StatET: Console terminates upon error On 11 March 2010 at 19:19, Janko Thyson wrote: | I'm trying to set up Eclispe (3.5.1) with the StatET-Plugin (0.8.1) under | Ubuntu (Karmic) and found it strange that my console terminates every time | something in a script produces an arbitrary error (e.g. just calling a | missing variable, trying to perform an illegal operation etc.). Can anyone | tell me why this happens or even better how to fix this? It so happens that I help a colleague recently to triage this. The problem there was that a recent rJava was needed + and installed -- and on Ubuntu and Debian this goes into /usr/local/lib/R/site-library/ and StatET -- as shipped -- does not look there. I don't use Eclipse so I don't recall where to set this, but in essence you need to make sure that StatET looks where R puts things. And that tends to be R .libPaths() [1] /usr/local/lib/R/site-library /usr/lib/R/site-library [3] /usr/lib/R/library R CCing Tobias just in case. Dirk __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
Re: [R] Ubunut + Eclipse + StatET: Console terminates upon error
On 11-Mar-10 19:19:26, Janko Thyson wrote: [...] First of, I'm still confused about Ubuntu's sudo way of doing things. Not knowing how to authorize me as root when installing packages from a R-script, I can't write on /usr/local/lib/R/site-library or /usr/lib/R/site-library. On this particular point: If, logged in as a user (whatever user you are), you enter the command into a terminal window: su - and then enter the root password when prompted, you will be logged in as root -- fair and square, and no nonsense. You will also be placed in root's home directory as well (not that of the user you previously were). Thereafter, you can do whatever you are used to doing as root. However, becoming root in the above way limits you to root access solely from the terminal window that you used for su - (though you could do the same in more than one terminal). All other windows, and the desktop itself, remain under the influence of the original user. The only way to take over an entire session as root would be to shut down the session (choosing Restart), and then log in as root at the initial login window for the new session. Then you would have to shut that down too when you wanted to resume normal life! Ted. E-Mail: (Ted Harding) ted.hard...@manchester.ac.uk Fax-to-email: +44 (0)870 094 0861 Date: 11-Mar-10 Time: 19:42:46 -- XFMail -- __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.
Re: [R] Ubunut + Eclipse + StatET: Console terminates upon error
I don't want to hijack the thread here, but since you mentioned hover pop-up help can you suggest a way to turn it OFF, totally and completely? Tom LaBone -- View this message in context: http://n4.nabble.com/Ubunut-Eclipse-StatET-Console-terminates-upon-error-tp1589479p1589800.html Sent from the R help mailing list archive at Nabble.com. __ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.