Learn R Programming

⚠️There's a newer version (1.7-83) of this package.Take me there.

terra (version 0.6-9)

Spatial Data Analysis

Description

Methods for spatial data analysis, especially raster data. Methods allow for low-level data manipulation as well as high-level global, local, zonal, and focal computation. The predict and interpolate methods facilitate the use of regression type (interpolation, machine learning) models for spatial prediction. Processing of very large files is supported. See the manual and tutorials on to get started. The package is similar to the 'raster' package; but it is simpler and faster.

Copy Link

Version

Install

install.packages('terra')

Monthly Downloads

183,196

Version

0.6-9

License

GPL (>= 3)

Maintainer

Last Published

May 19th, 2020

Functions in terra (0.6-9)

as.character

Create a text representation of (the skeleton of) an object
focal

Focal values
crop

Cut out a geographic subset
interpolate

Interpolate
freq

Frequency table
isLonLat

Check for longitude/latitude crs
pack

pack a Spat* object
aggregate

Aggregate raster cells
align

Align a SpatExtent with a SpatRaster
atan2

Two argument arc-tangent
plotRGB

Red-Green-Blue plot of a multi-layered SpatRaster
pairs

Pairs plot (matrix of scatterplots)
disaggregate

Disaggregate raster cells
boundaries

Detect boundaries (edges)
distance

Geographic distance
predict

Spatial model predictions
slope

Compute slopes
geom

Get the geometry (coordinates) of a SpatVector
gdal_info

GDALinfo
hist

Histogram
head and tail

Show the head or tail of a Spat* object
persp

Perspective plot
sources

Data sources of a SpatRaster
plot

Plot a SpatRaster or SpatVector
rasterize

Rasterize vector data
unique

Unique values
rast

Create a SpatRaster
values

Get cell values
xmin

Get or set single values of an extent
writeVector

Write vector data to a file
app

Apply a function to the cells of a SpatRaster
SpatDataFrame-class

C++ classes
area

Area and perimeter
draw

Draw a polygon, line, extent, or points
local

Local statistics
range

Get or compute the minimum and maximum cell values
clamp

Clamp values
modal

modal value
extend

Extend
mask

Mask values in a SpatRaster
project

Change the coordinate reference system
coerce

Coercion to other object types
collapse

Collapse cell values from a multi-layer SpatRaster
SpatExtent-class

Class "SpatExtent"
SpatRaster-class

SpatRaster class
compareGeom

Compare geometries of SpatRaster objects
tapp

Apply a function to subsets of layers of a SpatRaster
Summary

Summary
quantile

SpatRaster local quantiles
zoom

Zoom in on a map
vect

Create SpatVector objects
buffer

Create a buffer around vector objects or raster patches
contour

Contour plot
factors

Factors
writeRaster

Write raster data to a file
flip

Flip a raster
c

Combine
extent

Create, get or set a SpatExtent
ifel

ifelse for SpatRaster objects
extract

Extract values from a SpatRaster
crs

Get or set a coordinate reference system (projection)
density

Density plot
geomtype

Geometry type of a SpatVector
vector-attributes

Get or replace attribute values of a SpatVector
initialize

Initialize a SpatRaster with values
names

Names of Spat objects
global

global statistics
text

Add labels to a map
tmpFiles

Temporary files
resample

Transfer values of a SpatRaster to another one with a different geometry
select

Geometric subsetting
rotate

Rotate a SpatRaster along longitude
overlay

Overlay SpatRaster objects
shift

Shift
xyRowColCell

Coordinates from a row, column or cell number and vice versa
spatSample

Take a regular sample
terra-package

The "terra" package
SpatOptions-class

Inspect of set general options for "terra"
adjacent

Adjacent cells
zonal

Zonal statistics
SpatVector-class

Class "SpatVector"
classify

Classify (or reclassify) cell values
click

Query by clicking on a map
math

Arithmetic, logical and general mathematical methods
dimensions

Dimensions of a SpatRaster or SpatVector
diff

diff
merge

Merge SpatRaster or SpatExtent objects, or a SpatVector with a data.frame
read and write

Read from, or write to, file
rep

Combine
subset

Subset of a SpatRaster
subset-vector

Subset of a SpatVector
transpose

Transpose
trim

Trim a SpatRaster
as.data.frame

Get the attributes of a SpatVector
cover

Cover (replace) NA values with values of another raster