Learn R Programming

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

raster (version 1.9-5)

Geographic analysis and modeling with raster data

Description

Reading, writing, manipulating, analyzing and modeling of gridded spatial data. The package implements basic and high-level functions, as well as map algebra. Processing of very large files is supported.

Copy Link

Version

Install

install.packages('raster')

Monthly Downloads

153,616

Version

1.9-5

License

GPL (>= 3)

Maintainer

Robert Hijmans

Last Published

July 30th, 2011

Functions in raster (1.9-5)

Cluster

Use a multi-core (snow) cluster
dim

Dimensions of a Raster* object
Summary-methods

Summary methods
factors

Factors
intersectExtent

Extent intersection
as.logical

Change values to logical
as.raster

Coerce to a 'raster' object
focal

Focal
Extent coordinates

Coordinates of the Extent of a Raster object
Programming

Helper functions for programming
contour

Contour plot
cellValues

Obsolete functions
nlayers

Number of layers
plotRGB

Red-Green-Blue plot of a multi-layered Raster object
filledContour

Filled contour plot
head

Show the head or tail of a Raster* object
Logic-methods

Logical operators and functions
Math-methods

Mathematical functions
as.matrix

Get a matrix with raster cell values
rasterFromCells

Subset a raster by cell numbers
crop

Crop
misc stats

Miscellaneous statistical functions
rectify

rectify a Raster object
extension

Filename extensions
atan2

Two argument arc-tangent
adjacent

Adjacent cells
Arith-methods

Arithmic with Raster* objects
Extent-class

Class "Extent"
projectRaster

Project a Raster object
setMinMax

Compute min and max values
clump

Detect clumps
obsolete

Obsolete functions
drawExtent

Create an Extent object by drawing on a map
extremeValues

Minimum and maximum values
raster

Create a RasterLayer object
zoom

Zoom in on a plot
isLonLat

Is this longitude/latitude data?
polygonFromExtent

Polygon from Extent
setValues

Set values of a Raster object
KML

Write a KML or KMZ file
click

Click on a map
ncell

Number or rows, columns, and cells of a Raster* object
writeValues

Write values to a file
distance

Distance
getData

Get geographic data
calc

Calculate
clearValues

Clear values
as.data.frame

Get a data.frame with raster cell values
dataType

Data type
flip

Flip
sampleRegular

Regular sample
stackSelect

Select cell values from a multi-layer Raster* object
boxplot

Box plot of Raster objects
crosstab

Cross-tabulate
blockSize

Block size for writing files
Extract by index

Indexing to extract values of a Raster* object
cut

Convert values to classes
bands

Number of bands
extent

Extent
aggregate

Aggregate cells
datasource

Are values in memory and/or on disk?
density

Density plot
pointDistance

Distance between points
sampleRandom

Random sample
readAll

Read values from disk
initialize

Intitialize
Gain and offset

Gain and offset of values on file
addLayer

Add or drop a layer
persp

Perspective plot
movingFun

Moving functions
count

Count
freq

Frequency table
getValuesBlock

Get a block of raster cell values
mask

Mask values in a Raster object
adjacency

Adjacency
predict

Spatial model predictions
draw

Draw a line or polygon
autocorrelation

Spatial autocorrelation
properties

Raster file properties
xyFromCell

Coordinates from a row, column or cell number
alignExtent

Align an extent (object of class Extent)
cellFrom

Get cell, row, or column number
cellsFromExtent

Cells from Extent
rotated

Do the raster cells have a rotation?
distanceFromPoints

Distance from points
cover

Replace NA values with values of other layers
disaggregate

Disaggregate
direction

Direction
inifile

Read a .ini file
reclass

Reclassify
zApply

z (time) apply
Raster-class

Raster* classes
transpose

Transpose
compare

Compare
Slope and aspect

Slope and aspect
cellStats

Cell statistics
merge

Merge RasterLayers
rasterToContour

Raster to contour lines conversion
mosaic

Merge RasterLayers using a function for overlapping areas
expand

Expand
hillShade

Hill shading
plot

Plot a Raster* object
setExtent

Set the extent of a RasteLayer
resample

Resample a Raster object
getValues

Get raster cell values
update

Update raster cells of files (on disk)
image

Image
Options

Global options for the raster package
validCell

Validity of a cell, column or row number
trim

Trim
scalebar

scalebar
resolution

Resolution
hdr

Header files
round

Integer values
Summary

Summary
rotate

Rotate
filename

Filename
area

Size of cells
Compare-methods

Compare Raster* objects
unionExtent

Extent union
pairs

Pairs plot (matrix of scatterplots)
match

Value matching for Raster* objects
brick

Create a RasterBrick object
focalFilter

Focal filter
rowFromCell

Row or column number from a cell number
hist

Histogram
substitute

Substitute values in a RasterLayer
vector algebra

Algebra (notation) for overlaying SpatialPolygons*
rasterToPoints

Raster to points conversion
projection

Get or set a projection
rasterTmpFile

Temporary files
origin

Origin
which

Which cells are TRUE?
rasterToPolygons

Raster to polygons conversion
stackApply

Apply a function on subsets of a RasterStack or RasterBrick
raster-package

An overview of the functions in this package
rasterizeObsolete

Obsolete
stack

Create a RasterStack object
unique

Unique values
rasterize

Rasterize points, lines, or polygons
z-values

Get or set z-values
spplot

Use spplot to plot a Raster* object
unstack

Unstack
rasterFromXYZ

Create a RasterLayer from x, y, z values
NAvalue

Set the NA value of a RasterLayer
nudgeExtent

Round extent coordinates
cv

Coefficient of variation
approxNA

Estimate values for cells that are NA
subset

Subset layers in a Raster* object
writeRaster

Write raster data to a file
quantile

Raster quantiles
overlay

Overlay Raster objects
terrain

Terrain characteristics
zonal

Zonal statistics
gridDistance

Grid distance
extract

Extract values from Raster objects
modal

modal value
writeFormats

File types for writing
replacement

Replace cell values of a Raster* object
shift

Shift
interpolate

Interpolate
saverasterstack

Save or open a RasterStack file
edge

Edge detection
mergesp1

Merge a Spatial* object with a data.frame
SampleInt

Sample integer values
mergesp2

Spatially merge Spatial* objects
aggregatesp

Aggregate polygons
disaggregatesp

Disaggregate lines or polygons
select

Select features from Spatial objects