Reply to comment

  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /homepages/5/d120552937/htdocs/neil/drupal/or/includes/unicode.inc on line 345.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /homepages/5/d120552937/htdocs/neil/drupal/or/includes/unicode.inc on line 345.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /homepages/5/d120552937/htdocs/neil/drupal/or/includes/unicode.inc on line 345.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /homepages/5/d120552937/htdocs/neil/drupal/or/includes/unicode.inc on line 345.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /homepages/5/d120552937/htdocs/neil/drupal/or/includes/unicode.inc on line 345.
  • : preg_replace(): The /e modifier is deprecated, use preg_replace_callback instead in /homepages/5/d120552937/htdocs/neil/drupal/or/includes/unicode.inc on line 345.

Installing R GUI (JGR) on Ubuntu

I had the followoing error while trying to install JGR (included bellow).This problem is described in http://ubuntuforums.org/showthread.php?t=424921Although the suggestions listed there did not work for me.Here what did work:

  1. Unistall R from Ubuntu including all the packages etc.
  2. sudo apt-get install r-base-dev r-recommendedas suggested by http://stats.math.uni-augsburg.de/JGR/linux.shtml#faisty
  3. sudo apt-get install sun-java6-jdk
  4. sudo R CMD javareconf
  5. Then launch R: sudo R and inside of the R execute the following:
    1. install.packages('JGR', dep=TRUE)
    2. library(JGR)
    3. JGR()

Hope this works for you too  
--- Please select a CRAN mirror for use in this session ---
Loading Tcl/Tk interface ... done
also installing the dependencies ‘rJava’, ‘JavaGD’, ‘iplots’

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/rJava_0.5-1.tar.gz'
ftp data connection made, file length 230806 bytes
opened URL
==================================================
downloaded 225Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/JavaGD_0.4-3.tar.gz'
ftp data connection made, file length 87692 bytes
opened URL
==================================================
downloaded 85Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/iplots_1.1-1.tar.gz'
ftp data connection made, file length 326505 bytes
opened URL
==================================================
downloaded 318Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/JGR_1.5-8.tar.gz'
ftp data connection made, file length 436399 bytes
opened URL
==================================================
downloaded 426Kb

* Installing *source* package 'rJava' ...
checking for gcc... gcc-4.2 -std=gnu99
checking for C compiler default output file name...
configure: error: C compiler cannot create executables
See `config.log' for more details.
ERROR: configuration failed for package 'rJava'
** Removing '/usr/local/lib/R/site-library/rJava'
* Installing *source* package 'JavaGD' ...
checking for gcc... gcc-4.2 -std=gnu99
checking for C compiler default output file name...
configure: error: C compiler cannot create executables
See `config.log' for more details.
ERROR: configuration failed for package 'JavaGD'
** Removing '/usr/local/lib/R/site-library/JavaGD'
* Installing *source* package 'iplots' ...
** R
** inst
** preparing package for lazy loading
Error: package 'rJava' required by 'iplots' could not be found
Execution halted
ERROR: lazy loading failed for package 'iplots'
** Removing '/usr/local/lib/R/site-library/iplots'
* Installing *source* package 'JGR' ...
** R
** inst
** help
>>> Building/Updating help pages for package 'JGR'
Formats: text html latex example
jgr.addMenu text html latex example
jgr.addMenuItem text html latex example
jgr.addMenuSeperator text html latex example
supplements text html latex
** building package indices ...
* DONE (JGR)

The downloaded packages are in
/tmp/RtmpC5iOXg/downloaded_packages
Warning messages:
1: installation of package 'rJava' had non-zero exit status in: install.packages("JGR")
2: installation of package 'JavaGD' had non-zero exit status in: install.packages("JGR")
3: installation of package 'iplots' had non-zero exit status in: install.packages("JGR")
> q()
Save workspace image? [y/n/c]: n
neil@b4:~$ sudo apt-get install sun-java6-jdk
Reading package lists... Done
Building dependency tree
Reading state information... Done
sun-java6-jdk is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
neil@b4:~$ sudo R CMD javareconf
Java interpreter : /usr/bin/java
Java version : 1.6.0_03
Java home path : /usr/lib/jvm/java-6-sun-1.6.0.03/jre
Java compiler : /usr/bin/javac
Java headers gen.: /usr/bin/javah
Java archive tool: /usr/bin/jar
Java library path: $(JAVA_HOME)/lib/i386/server:$(JAVA_HOME)/lib/i386:$(JAVA_HOME)/../lib/i386::/usr/java/packages/lib/i386:/lib:/usr/lib
JNI linker flags : -L$(JAVA_HOME)/lib/i386/server -L$(JAVA_HOME)/lib/i386 -L$(JAVA_HOME)/../lib/i386 -L -L/usr/java/packages/lib/i386 -L/lib -L/usr/lib -ljvm
JNI cpp flags : -I/usr/lib/jvm/java-6-sun-1.6.0.03/jre/../include -I/usr/lib/jvm/java-6-sun-1.6.0.03/jre/../include/linux

Updating Java configuration in /etc/R
Done.

neil@b4:~$ sudo R

R version 2.5.1 (2007-06-27)
Copyright (C) 2007 The R Foundation for Statistical Computing
ISBN 3-900051-07-0

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

Natural language support but running in an English locale

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> install.packages('JGR')
Warning in install.packages("JGR") : argument 'lib' is missing: using '/usr/local/lib/R/site-library'
--- Please select a CRAN mirror for use in this session ---
Loading Tcl/Tk interface ... done
also installing the dependencies ‘rJava’, ‘JavaGD’, ‘iplots’

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/rJava_0.5-1.tar.gz'
ftp data connection made, file length 230806 bytes
opened URL
==================================================
downloaded 225Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/JavaGD_0.4-3.tar.gz'
ftp data connection made, file length 87692 bytes
opened URL
==================================================
downloaded 85Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/iplots_1.1-1.tar.gz'
ftp data connection made, file length 326505 bytes
opened URL
==================================================
downloaded 318Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/JGR_1.5-8.tar.gz'
ftp data connection made, file length 436399 bytes
opened URL
==================================================
downloaded 426Kb

* Installing *source* package 'rJava' ...
checking for gcc... gcc-4.2 -std=gnu99
checking for C compiler default output file name...
configure: error: C compiler cannot create executables
See `config.log' for more details.
ERROR: configuration failed for package 'rJava'
** Removing '/usr/local/lib/R/site-library/rJava'
* Installing *source* package 'JavaGD' ...
checking for gcc... gcc-4.2 -std=gnu99
checking for C compiler default output file name...
configure: error: C compiler cannot create executables
See `config.log' for more details.
ERROR: configuration failed for package 'JavaGD'
** Removing '/usr/local/lib/R/site-library/JavaGD'
* Installing *source* package 'iplots' ...
** R
** inst
** preparing package for lazy loading
Error: package 'rJava' required by 'iplots' could not be found
Execution halted
ERROR: lazy loading failed for package 'iplots'
** Removing '/usr/local/lib/R/site-library/iplots'
* Installing *source* package 'JGR' ...
** R
** inst
** help
>>> Building/Updating help pages for package 'JGR'
Formats: text html latex example
jgr.addMenu text html latex example
jgr.addMenuItem text html latex example
jgr.addMenuSeperator text html latex example
supplements text html latex
** building package indices ...
* DONE (JGR)

The downloaded packages are in
/tmp/RtmpNJmxA6/downloaded_packages
Warning messages:
1: installation of package 'rJava' had non-zero exit status in: install.packages("JGR")
2: installation of package 'JavaGD' had non-zero exit status in: install.packages("JGR")
3: installation of package 'iplots' had non-zero exit status in: install.packages("JGR")
> install.packages("JGR",dep=TRUE)
Warning in install.packages("JGR", dep = TRUE) :
argument 'lib' is missing: using '/usr/local/lib/R/site-library'
also installing the dependencies ‘mapproj’, ‘maps’, ‘CarbonEL’, ‘rJava’, ‘JavaGD’, ‘iplots’

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/mapproj_1.1-7.1.tar.gz'
ftp data connection made, file length 1019466 bytes
opened URL
==================================================
downloaded 995Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/maps_2.0-39.tar.gz'
ftp data connection made, file length 1523841 bytes
opened URL
==================================================
downloaded 1488Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/CarbonEL_0.1-4.tar.gz'
ftp data connection made, file length 2959 bytes
opened URL
==================================================
downloaded 2959 bytes

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/rJava_0.5-1.tar.gz'
ftp data connection made, file length 230806 bytes
opened URL
==================================================
downloaded 225Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/JavaGD_0.4-3.tar.gz'
ftp data connection made, file length 87692 bytes
opened URL
==================================================
downloaded 85Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/iplots_1.1-1.tar.gz'
ftp data connection made, file length 326505 bytes
opened URL
==================================================
downloaded 318Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/JGR_1.5-8.tar.gz'
ftp data connection made, file length 436399 bytes
opened URL
==================================================
downloaded 426Kb

* Installing *source* package 'maps' ...
** libs
** arch -
gcc-4.2 -std=gnu99 -g -O2 Gmake.c -o Gmake
/bin/bash: gcc-4.2: command not found
make: *** [Gmake] Error 127
ERROR: compilation failed for package 'maps'
** Removing '/usr/local/lib/R/site-library/maps'
* Installing *source* package 'CarbonEL' ...
** libs
gcc-4.2 -std=gnu99 -I/usr/share/R/include -I/usr/share/R/include -fpic -g -O2 -c ael.c -o ael.o
/bin/bash: gcc-4.2: command not found
make: *** [ael.o] Error 127
ERROR: compilation failed for package 'CarbonEL'
** Removing '/usr/local/lib/R/site-library/CarbonEL'
* Installing *source* package 'rJava' ...
checking for gcc... gcc-4.2 -std=gnu99
checking for C compiler default output file name...
configure: error: C compiler cannot create executables
See `config.log' for more details.
ERROR: configuration failed for package 'rJava'
** Removing '/usr/local/lib/R/site-library/rJava'
* Installing *source* package 'JavaGD' ...
checking for gcc... gcc-4.2 -std=gnu99
checking for C compiler default output file name...
configure: error: C compiler cannot create executables
See `config.log' for more details.
ERROR: configuration failed for package 'JavaGD'
** Removing '/usr/local/lib/R/site-library/JavaGD'
* Installing *source* package 'mapproj' ...
** libs
gcc-4.2 -std=gnu99 -I/usr/share/R/include -I/usr/share/R/include -fpic -g -O2 -c aitoff.c -o aitoff.o
/bin/bash: gcc-4.2: command not found
make: *** [aitoff.o] Error 127
ERROR: compilation failed for package 'mapproj'
** Removing '/usr/local/lib/R/site-library/mapproj'
* Installing *source* package 'iplots' ...
** R
** inst
** preparing package for lazy loading
Error: package 'rJava' required by 'iplots' could not be found
Execution halted
ERROR: lazy loading failed for package 'iplots'
** Removing '/usr/local/lib/R/site-library/iplots'
* Installing *source* package 'JGR' ...
** R
** inst
** help
>>> Building/Updating help pages for package 'JGR'
Formats: text html latex example
jgr.addMenu text html latex example
jgr.addMenuItem text html latex example
jgr.addMenuSeperator text html latex example
supplements text html latex
** building package indices ...
* DONE (JGR)

The downloaded packages are in
/tmp/RtmpNJmxA6/downloaded_packages
Warning messages:
1: installation of package 'maps' had non-zero exit status in: install.packages("JGR", dep = TRUE)
2: installation of package 'CarbonEL' had non-zero exit status in: install.packages("JGR", dep = TRUE)
3: installation of package 'rJava' had non-zero exit status in: install.packages("JGR", dep = TRUE)
4: installation of package 'JavaGD' had non-zero exit status in: install.packages("JGR", dep = TRUE)
5: installation of package 'mapproj' had non-zero exit status in: install.packages("JGR", dep = TRUE)
6: installation of package 'iplots' had non-zero exit status in: install.packages("JGR", dep = TRUE)
> q()
Save workspace image? [y/n/c]: n
neil@b4:~$ sudo update-alternatives --config java

There are 2 alternatives which provide `java'.

Selection Alternative
-----------------------------------------------
1 /usr/bin/gij-4.2
*+ 2 /usr/lib/jvm/java-6-sun/jre/bin/java

Press enter to keep the default[*], or type selection number: 2
Using `/usr/lib/jvm/java-6-sun/jre/bin/java' to provide `java'.
neil@b4:~$ sudo R CMD javareconf
Java interpreter : /usr/bin/java
Java version : 1.6.0_03
Java home path : /usr/lib/jvm/java-6-sun-1.6.0.03/jre
Java compiler : /usr/bin/javac
Java headers gen.: /usr/bin/javah
Java archive tool: /usr/bin/jar
Java library path: $(JAVA_HOME)/lib/i386/server:$(JAVA_HOME)/lib/i386:$(JAVA_HOME)/../lib/i386::/usr/java/packages/lib/i386:/lib:/usr/lib
JNI linker flags : -L$(JAVA_HOME)/lib/i386/server -L$(JAVA_HOME)/lib/i386 -L$(JAVA_HOME)/../lib/i386 -L -L/usr/java/packages/lib/i386 -L/lib -L/usr/lib -ljvm
JNI cpp flags : -I/usr/lib/jvm/java-6-sun-1.6.0.03/jre/../include -I/usr/lib/jvm/java-6-sun-1.6.0.03/jre/../include/linux

Updating Java configuration in /etc/R
Done.

neil@b4:~$ r
The program 'r' is currently not installed. You can install it by typing:
sudo apt-get install littler
bash: r: command not found
neil@b4:~$ sudo R

R version 2.5.1 (2007-06-27)
Copyright (C) 2007 The R Foundation for Statistical Computing
ISBN 3-900051-07-0

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

Natural language support but running in an English locale

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> install.packages("JGR",dep=TRUE)
Warning in install.packages("JGR", dep = TRUE) :
argument 'lib' is missing: using '/usr/local/lib/R/site-library'
--- Please select a CRAN mirror for use in this session ---
Loading Tcl/Tk interface ... done
also installing the dependencies ‘mapproj’, ‘maps’, ‘CarbonEL’, ‘rJava’, ‘JavaGD’, ‘iplots’

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/mapproj_1.1-7.1.tar.gz'
ftp data connection made, file length 1019466 bytes
opened URL
==================================================
downloaded 995Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/maps_2.0-39.tar.gz'
ftp data connection made, file length 1523841 bytes
opened URL
==================================================
downloaded 1488Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/CarbonEL_0.1-4.tar.gz'
ftp data connection made, file length 2959 bytes
opened URL
==================================================
downloaded 2959 bytes

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/rJava_0.5-1.tar.gz'
ftp data connection made, file length 230806 bytes
opened URL
==================================================
downloaded 225Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/JavaGD_0.4-3.tar.gz'
ftp data connection made, file length 87692 bytes
opened URL
==================================================
downloaded 85Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/iplots_1.1-1.tar.gz'
ftp data connection made, file length 326505 bytes
opened URL
==================================================
downloaded 318Kb

trying URL 'ftp://ftp.ecc.u-tokyo.ac.jp/CRAN/src/contrib/JGR_1.5-8.tar.gz'
ftp data connection made, file length 436399 bytes
opened URL
==================================================
downloaded 426Kb

* Installing *source* package 'maps' ...
** libs
** arch -
gcc-4.2 -std=gnu99 -g -O2 Gmake.c -o Gmake
/bin/bash: gcc-4.2: command not found
make: *** [Gmake] Error 127
ERROR: compilation failed for package 'maps'
** Removing '/usr/local/lib/R/site-library/maps'
* Installing *source* package 'CarbonEL' ...
** libs
gcc-4.2 -std=gnu99 -I/usr/share/R/include -I/usr/share/R/include -fpic -g -O2 -c ael.c -o ael.o
/bin/bash: gcc-4.2: command not found
make: *** [ael.o] Error 127
ERROR: compilation failed for package 'CarbonEL'
** Removing '/usr/local/lib/R/site-library/CarbonEL'
* Installing *source* package 'rJava' ...
checking for gcc... gcc-4.2 -std=gnu99
checking for C compiler default output file name...
configure: error: C compiler cannot create executables
See `config.log' for more details.
ERROR: configuration failed for package 'rJava'
** Removing '/usr/local/lib/R/site-library/rJava'
* Installing *source* package 'JavaGD' ...
checking for gcc... gcc-4.2 -std=gnu99
checking for C compiler default output file name...
configure: error: C compiler cannot create executables
See `config.log' for more details.
ERROR: configuration failed for package 'JavaGD'
** Removing '/usr/local/lib/R/site-library/JavaGD'
* Installing *source* package 'mapproj' ...
** libs
gcc-4.2 -std=gnu99 -I/usr/share/R/include -I/usr/share/R/include -fpic -g -O2 -c aitoff.c -o aitoff.o
/bin/bash: gcc-4.2: command not found
make: *** [aitoff.o] Error 127
ERROR: compilation failed for package 'mapproj'
** Removing '/usr/local/lib/R/site-library/mapproj'
* Installing *source* package 'iplots' ...
** R
** inst
** preparing package for lazy loading
Error: package 'rJava' required by 'iplots' could not be found
Execution halted
ERROR: lazy loading failed for package 'iplots'
** Removing '/usr/local/lib/R/site-library/iplots'
* Installing *source* package 'JGR' ...
** R
** inst
** help
>>> Building/Updating help pages for package 'JGR'
Formats: text html latex example
jgr.addMenu text html latex example
jgr.addMenuItem text html latex example
jgr.addMenuSeperator text html latex example
supplements text html latex
** building package indices ...
* DONE (JGR)

The downloaded packages are in
/tmp/RtmpRJsdYj/downloaded_packages
Warning messages:
1: installation of package 'maps' had non-zero exit status in: install.packages("JGR", dep = TRUE)
2: installation of package 'CarbonEL' had non-zero exit status in: install.packages("JGR", dep = TRUE)
3: installation of package 'rJava' had non-zero exit status in: install.packages("JGR", dep = TRUE)
4: installation of package 'JavaGD' had non-zero exit status in: install.packages("JGR", dep = TRUE)
5: installation of package 'mapproj' had non-zero exit status in: install.packages("JGR", dep = TRUE)
6: installation of package 'iplots' had non-zero exit status in: install.packages("JGR", dep = TRUE)
> q()
Save workspace image? [y/n/c]: n
neil@b4:~$ R
The program 'R' is currently not installed. You can install it by typing:
sudo apt-get install r-base-core
bash: R: command not found

 

Reply

  • Web page addresses and e-mail addresses turn into links automatically.
  • Allowed HTML tags: <a> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd>
  • Lines and paragraphs break automatically.

More information about formatting options