Learn R Programming

raster (version 1.8-3)

pairs: Pairs plot (matrix of scatterplots)

Description

Pair plots of layers in a RasterStack or RasterBrick

Usage

pairs(x, ...)

Arguments

x
RasterBrick or RasterStack
...
Additional arguments. See Methods

Methods

pairs(x, hist=TRUE, cor=TRUE, maxpixels=100000) rll{ hist Logical. If TRUE a histogram of the values is shown on the diagonal cor Logical. If TRUE the correlation coefficient is shown in the upper panels maxpixels Integer. Number of pixels to sample from each layer of large Raster objects }

See Also

boxplot, hist, density

Examples

Run this code
r <- raster(system.file("external/test.grd", package="raster") )
s <- stack(r, 1/r, sqrt(r))
pairs(s)

# to make indvidual histograms:
hist(r)
# or scatter plots:
plot(r, 1/r)

Run the code above in your browser using DataLab