Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Column
width900px


Code Block
languagebash
themeEmacs
titleTerminal 2. Install with R install.packages()
> install.packages('Rcpp')
Installing package into ‘/group/projcode/rsrchr/software/r/3.6’
(as ‘lib’ is unspecified)
trying URL 'https://cran.curtin.edu.au/src/contrib/Rcpp_1.0.6.tar.gz'
Content type 'application/x-gzip' length 2952876 bytes (2.8 MB)
==================================================
downloaded 2.8 MB

* installing *source* package ‘Rcpp’ ...
** package ‘Rcpp’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c api.cpp -o api.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c attributes.cpp -o attributes.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c barrier.cpp -o barrier.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c date.cpp -o date.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c module.cpp -o module.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c rcpp_init.cpp -o rcpp_init.o
g++ -std=gnu++11 -shared -L/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/lib -L/usr/local/lib64 -o Rcpp.so api.o attributes.o barrier.o date.o module.o rcpp_init.o -L/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/lib -lR
installing to /group/projcode/rsrchr/software/r/3.6/00LOCK-Rcpp/00new/Rcpp/libs
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** checking absolute paths in shared objects and dynamic libraries
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (Rcpp)

The downloaded source packages are in
	‘/tmp/Rtmp39wZil/downloaded_packages’
> 

Install a package using R CMD INSTALL

R also provides a Linux shell option to install packages, via the command R CMD INSTALL. This command requires the package tarball to be already downloaded. It will not take care of any dependencies, so it is an effective method only for simple installations.

Let's load the R module:

$ module load r/4.1.0

Now let's install Rcpp from its downloaded tarball:

...

width900px



...

If you want to install this package in a different location to /software/projects/<project-id>/<user-name>/setonix/r/%v above, you can specify the install location by adding the lib=/install/path/for/package flag, as shown in the example below:

Column
width900px


$ R CMD INSTALL Rcpp_1.0.6.tar.gz * installing to library ‘/group/projcode/rsrchr/software/r/3.6’
Code Block
languagebash
themeEmacs
titleTerminal 3. Install with R CMD INSTALL
Specify install location with lib= flag
> install.packages('Rcpp', lib='/group/diff_projcode/rsrchr/software/r/3.6')
Installing package into ‘/group/diff_projcode/rsrchr/software/r/3.6’
(as ‘lib’ is unspecified)
trying URL 'https://cran.curtin.edu.au/src/contrib/Rcpp_1.0.6.tar.gz'
Content type 'application/x-gzip' length 2952876 bytes (2.8 MB)
==================================================
downloaded 2.8 MB

* installing *source* package ‘Rcpp’ ...
** package ‘Rcpp’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c api.cpp -o api.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c attributes.cpp -o attributes.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c barrier.cpp -o barrier.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c date.cpp -o date.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c module.cpp -o module.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c rcpp_init.cpp -o rcpp_init.o
g++ -std=gnu++11 -shared -L/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/lib -L/usr/local/lib64 -o Rcpp.so api.o attributes.o barrier.o date.o module.o rcpp_init.o -L/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/lib -lR
installing to /group/diff_projcode/rsrchr/software/r/3.6/00LOCK-Rcpp/00new/Rcpp/libs
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** checking absolute paths in shared objects and dynamic libraries
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (Rcpp)

The downloaded source packages are in
	‘/tmp/Rtmp39wZil/downloaded_packages’
> 


Install a package using R CMD INSTALL

R also provides a Linux shell option to install packages, via the command R CMD INSTALL. This command requires the package tarball to be already downloaded. It will not take care of any dependencies, so it is an effective method only for simple installations.

Let's load the R module:

$ module load r/4.1.0

Now let's install Rcpp from its downloaded tarball:

Column
width900px


Code Block
languagebash
themeEmacs
titleTerminal 3. Install with R CMD INSTALL
$ R CMD INSTALL Rcpp_1.0.6.tar.gz 
* installing to library ‘/group/projcode/rsrchr/software/r/3.6’
* installing *source* package ‘Rcpp’ ...
** package ‘Rcpp’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c api.cpp -o api.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c attributes.cpp -o attributes.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c barrier.cpp -o barrier.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c date.cpp -o date.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c module.cpp -o module.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c rcpp_init.cpp -o rcpp_init.o
g++ -std=gnu++11 -shared -L/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/lib -L/usr/local/lib64 -o Rcpp.so api.o attributes.o barrier.o date.o module.o rcpp_init.o -L/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/lib -lR
installing to /group/projcode/rsrchr/software/r/3.6/00LOCK-Rcpp/00new/Rcpp/libs
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** checking absolute paths in shared objects and dynamic libraries
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (Rcpp)



An alternative way to install from a tarball is to use the install.packages("Rcpp_1.0.6.tar.gz"). This assumes the tarball is in your working directory. It is also possible to additionally specify the installation location by adding the  lib=/install/path/for/package flag.

Let's load the R module:


$ module load r/4.1.0


Now let's install Rcpp from its downloaded tarball and specify the install location:

Column
width900px


Code Block
languagebash
themeEmacs
titleTerminal 5. Install from tarball with install.packages()
> install.packages('Rcpp_1.0.6.tar.gz', lib='/group/diff_projcode/rsrchr/software/r/3.6')
Installing package into ‘/group/diff_projcode/rsrchr/software/r/3.6’
(as ‘lib’ is unspecified)
trying URL 'https://cran.curtin.edu.au/src/contrib/Rcpp_1.0.6.tar.gz'
Content type 'application/x-gzip' length 2952876 bytes (2.8 MB)
==================================================
downloaded 2.8 MB

* installing *source* package ‘Rcpp’ ...
** package ‘Rcpp’ successfully unpacked and MD5 sums checked
** using staged installation
** libs
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c api.cpp -o api.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c attributes.cpp -o attributes.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c barrier.cpp -o barrier.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c date.cpp -o date.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c module.cpp -o module.o
g++ -std=gnu++11 -I"/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/include" -DNDEBUG -I../inst/include/  -I/usr/local/include  -fpic  -g -O2  -c rcpp_init.cpp -o rcpp_init.o
g++ -std=gnu++11 -shared -L/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/lib -L/usr/local/lib64 -o Rcpp.so api.o attributes.o barrier.o date.o module.o rcpp_init.o -L/pawsey/sles12sp3/apps/sandybridge/gcc/4.8.5/r/3.6.3/lib64/R/lib -lR
installing to /group/diff_projcode/rsrchr/software/r/3.6/00LOCK-Rcpp/00new/Rcpp/libs
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** checking absolute paths in shared objects and dynamic libraries
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (Rcpp)

The downloaded source packages are in
	‘/tmp/Rtmp39wZil/downloaded_packages’
> 


Related pages

...