Learn R Programming

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

raster (version 1.7-18)

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

107,973

Version

1.7-18

License

GPL (>= 3)

Maintainer

Robert Hijmans

Last Published

December 21st, 2010

Functions in raster (1.7-18)

compare

Compare
rasterToPolygons

Raster to polygons conversion
crop

Crop
extent

Extent
cellsFromExtent

Cells from Extent
rasterFromCells

Subset a raster by cell numbers
aggregate

Aggregate cells
hist

Histogram
initialize

Intitialize
setExtent

Set the extent of a RasteLayer
draw

Draw a line or polygon
boxplot

Box plot of Raster objects
adjacency

Adjacency
alignExtent

Align an extent (object of class Extent)
nlayers

Number of layers
as.matrix

Get a matrix with raster cell values
extremeValues

Minimum and maximum values
cellStats

Cell statistics
disaggregate

Disaggregate
KML

Write a KML file
Raster-class

Raster* classes
cut

Convert values to classes
density

Density plot
distanceFromPoints

Distance from points
quantile

Raster quantiles
contour

Contour plot
reclass

Reclassify
expand

Expand
freq

Frequency table
isLonLat

Is this longitude/latitude data?
image

Image
getValuesBlock

Get a block of raster cell values
inifile

Read a .ini file
focal

Focal
predict

Spatial model predictions
distance

Distance
addLayer

Add or drop a layer
projection

Get or set a projection
resample

Resample
count

Count
Compare-methods

Compare Raster* objects
ncell

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

Save or open a RasterStack file
plotRGB

Red-Green-Blue plot of a multi-layered Raster object
Summary-methods

Summary methods
direction

Direction
rasterToPoints

Raster to points conversion
pairs

Pairs plot (matrix of scatterplots)
mask

Mask values in a Raster object
brick

Create a RasterBrick object
getData

Get geographic data
clearValues

Clear values
Extent-class

Class "Extent"
Options

Global options for the raster package
Programming

Helper functions for programming
area

Size of cells
edge

Edge detection
drawExtent

Draw extet
filename

Filename
Math-methods

Mathematical functions
Gain and offset

Gain and offset of values on file
Cluster

Use a multi-core (snow) cluster
bands

Number of bands
rotate

Rotate
click

Click on a map
intersectExtent

Extent intersection
unique

Unique values
focalFilter

Focal filter
cellFrom

Get cell, row, or column number
getValues

Get raster cell values
crosstab

Cross-tabulate
as.logical

Change values to logical
plot3D

Interactive 3D plot of a RasterLayer
round

Integer values
extension

Filename extensions
blockSize

Block size for writing files
polygonFromExtent

Polygon from Extent
dim

Dimensions of a Raster* object
rasterFromXYZ

Create a RasterLayer from x, y, z values
SampleInt

Sample integer values
factors

Factors
pointDistance

Distance between points
sampleRegular

Regular sample
clump

Detect clumps
rowFromCell

Row or column number from a cell number
rasterizeObsolete

Obsolete
plot

Plot a Raster* object
nudgeExtent

Round extent coordinates
shift

Shift
extract

Extract values from Raster objects
resolution

Resolution
filledContour

Filled contour plot
indexing

Extract or replace cell values of a Raster object
validCell

Validity of a cell, column or row number
sampleRandom

Random sample
flip

Flip
mosaic

Merge RasterLayers using a function for overlapping areas
hdr

Header files
substitute

Substitute values in a RasterLayer
zoom

Zoom in on a plot
merge

Merge RasterLayers
projectRaster

Project a Raster object
origin

Origin
transpose

transpose
stackApply

Apply a function on subsets of a RasterStack or RasterBrick
rasterize

Rasterize points, lines, or polygons
setMinMax

Compute min and max values
obsolete

Obsolete functions
raster-package

Management, analysis and modeling of raster-type geographic data
setValues

Set values of a Raster object
stack

Create a RasterStack object
readAll

Read values from disk
rasterTmpFile

Temporary files
Summary

Summary
zonal

Zonal statistics
writeRaster

Write raster data to a file
Logic-methods

Logical operators and functions
which

Which cells are TRUE?
unionExtent

Extent union
update

Update raster cells of files (on disk)
xyFromCell

Coordinates from a row, column or cell number
writeFormats

File types for writing
writeValues

Write values to a file
coordinates

Coordinates
gridDistance

Grid distance
rasterToContour

Raster to contour lines conversion
raster

Create a RasterLayer object
unstack

Unstack
subset

Subset layers in a Raster* object
NAvalue

Set the NA value of a RasterLayer
Arith-methods

Arithmic with Raster* objects
calc

Calculate
cover

Replace NA values with values of other layers
datasource

Are values in memory and/or on disk?
head

Show the head or tail of the values of a RasterLaayer
persp

Perspective plot
stats

Miscellaneous statistical functions
trim

Trim
cellValues

Extract values for one or more cells / points
interpolate

Interpolate
dataType

Data type
overlay

Overlay Raster objects
properties

Raster file properties