This package offers a set of handy tool functions for reading and processing spatial data. The aim of these functions is to supply the workflow to create thematic maps, e.g. read shape files, set map projections, append data, calculate areas and distances, and query OpenStreetMap. The visualization of thematic maps can be done with the tmap package.
tmaptools
is available on CRAN (version 1.2-1). The development version can be installed as follows:
library(devtools)
install_github("mtennekes/tmaptools")
The tmaptools
packages relies on the R packages rgdal
and rgeos
, which depend on the external libraries gdal
, proj.4
and geos
. On Windows, these are embedded in rgdal
and rgeos
. On Linux (Ubuntu), these libraries can be installed as follows:
sudo apt-get install libgdal-dev
sudo apt-get install libproj-dev
sudo apt-get install libgeos-dev
See source pages for gdal, proj, and geos. For Mac OS users, see http://www.kyngchaos.com.
Also, tmaptools
relies indirectly on the R package V8
. For Linux (Ubuntu), the v8
library needs to be installed for this:
sudo apt-get install libv8-dev
Java is required for obtaining OpenStreetMap bitmaps (with the functionread_osm
). It can be installed in Linux (Ubuntu) with:
sudo apt-get install openjdk-9-jre
sudo R CMD javareconf
Odd numbered versions will be development versions and even numbered versions stable CRAN releases (as with data.table).
The latest development version can be installed using devtools
.
library(devtools)
install_github("mtennekes/tmaptools")