- Notifications
You must be signed in to change notification settings - Fork104
R package for spatial data handlinghttps://rspatial.github.io/terra/reference/terra-package.html
License
rspatial/terra
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
logo by Zane Dax
terra is anR package for spatial data analysis. There are tutorials atrspatial.org.
Stack Overflow is a good place to ask questions if you get stuck. Make sure to include asimple reproducible example. But if you think you have found a bug, or if you want to request a new feature, please file anissue.
terra replaces theraster package. The interfaces ofterra andraster are similar, butterra is simpler, faster and can do more.
terra is available from CRAN, so you can useinstall.packages("terra") to get the currentreleased version.
The easiest way to use thedevelopment version on Windows or MacOS, is to install it from theR-universe, like this:
install.packages('terra', repos='https://rspatial.r-universe.dev')To install from source-code, first install theRcpp package that terra depends on:
install.packages("Rcpp")And then continue based on the OS you are using.
On Windows, you need to first installRtools to get, among other things, a C++ compiler thatR can use. You need the current versions ofR andRTools.
Then, inR, install terra with:
remotes::install_github("rspatial/terra")On macOS, you can useMacPorts orHomebrew.
With MacPorts you can do
sudo port install R-terraWith Homebrew, you need to first install GDAL and PROJ:
brew install pkg-configbrew install gdal projFollowed by (note the additional configuration argument needed for Homebrew)
remotes::install_github("rspatial/terra", configure.args = "--with-proj-lib=$(brew --prefix)/lib/")To install the CRAN version from source you would do
install.packages("terra", type = "source", configure.args = "--with-proj-lib=$(brew --prefix)/lib/")Theeasy way to install terra on Ubuntu is withr2u.
The harder way:
Install the system requirements GDAL (>= 2.2.3), GEOS (>= 3.4.0), PROJ (>= 4.9.3), netcdf (>=4.1.3), sqlite3, tbb
sudo add-apt-repository ppa:ubuntugis/ubuntugis-unstablesudo apt-get updatesudo apt-get install libgdal-dev libgeos-dev libproj-dev libtbb-dev libnetcdf-devAnd now, in R, install the package
remotes::install_github("rspatial/terra")See thesfinstructions for installation on other linux systems --- and for possible updates/improvements on the above instructions.
About
R package for spatial data handlinghttps://rspatial.github.io/terra/reference/terra-package.html
Topics
Resources
License
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
Uh oh!
There was an error while loading.Please reload this page.
