Last chance! 50% off unlimited learning
Sale ends in
plotRGB(x, r=1, g=2, b=3, scale, maxpixels=500000, extent=NULL, ...)
x
a RasterBrick or RasterStack object
r
Integer. Index of the Red channel, between 1 and nlayers(x)
g
Integer. Index of the Green channel, between 1 and nlayers(x)
b
Integer. Index of the Blue channel, between 1 and nlayers(x)
scale
Integer. Maximum (possible) value in the three channels. Defaults to 255 or to the maximum value of x
if that is known and larger than 255
maxpixels
Maximum number of pixels to use
extent
An extent object to zoom in a region
...
graphical parameters as in rasterImage
}plot
b <- brick(system.file("external/rlogo.grd", package="raster"))
plotRGB(b)
plotRGB(b, 3, 2, 1)
Run the code above in your browser using DataLab