Difference between revisions of "R"

From gnewarchaeology wiki
Jump to: navigation, search
Line 17: Line 17:
 
* [http://cran.mirror.garr.it/mirrors/CRAN/]
 
* [http://cran.mirror.garr.it/mirrors/CRAN/]
  
For a backport of R 3.2.3 to jessie, simply add something like
+
For a backport of the latest stable version of R to jessie, simply add something like
  
 
<code>
 
<code>
Line 32: Line 32:
 
$ apt-key adv --keyserver keys.gnupg.net --recv-key 381BA480
 
$ apt-key adv --keyserver keys.gnupg.net --recv-key 381BA480
 
</syntaxhighlight>
 
</syntaxhighlight>
 +
 +
Then install the newest R release including recommended packages
  
 
<syntaxhighlight lang="bash">
 
<syntaxhighlight lang="bash">
 +
$ sudo apt-get update
 
$ sudo apt-get install r-base
 
$ sudo apt-get install r-base
 +
</syntaxhighlight>
 +
 +
You may want to install the automatically tuned Atlas or the multi-threaded OpenBlas library in order to get higher performance for linear algebra operations
 +
 +
<syntaxhighlight lang="bash">
 +
# Atlas
 +
$ sudo apt-get install libatlas3-base
 +
 +
# OpenBlas library
 +
$ sudo apt-get install libopenblas-base
 
</syntaxhighlight>
 
</syntaxhighlight>
  

Revision as of 10:33, 22 January 2016

R



References

Install & Configure

Install R from your preferred CRAN mirror.

For a backport of the latest stable version of R to jessie, simply add something like

deb http://<favourite-cran-mirror>/bin/linux/debian jessie-cran3/

deb-src <favourite-cran-mirror>/bin/linux/debian jessie-cran3/

to the file /etc/apt/sources.list on your computer. You need to substitute <favourite-cran-mirror> by one of the mirror URLs listed in the mirror list.

The Debian backports archives on CRAN are signed with the key of Johannes Ranke (CRAN Debian archive) <jranke@uni-bremen.de> with key ID 381BA480. You can fetch and import this with

$ apt-key adv --keyserver keys.gnupg.net --recv-key 381BA480

Then install the newest R release including recommended packages

$ sudo apt-get update
$ sudo apt-get install r-base

You may want to install the automatically tuned Atlas or the multi-threaded OpenBlas library in order to get higher performance for linear algebra operations

# Atlas
$ sudo apt-get install libatlas3-base

# OpenBlas library
$ sudo apt-get install libopenblas-base

Install RStudio from [2]

Data import & export

PostgreSQL/PostGIS connection

Applied Spatial Data Analysis with R

  • Roger S. Bivand, Edzer J. Pebesma and V. Gómez-Rubio. UseR! Series, Springer, 2008, 378 p., Softcover ISBN: 978-0-387-78170-9

Spatial Point Pattern Analysis

Geostatistics

Areal Data and Spatial Autocorrelation