RGB {raster} | R Documentation |
Create a Red-Green-Blue Raster object
Description
Make a Red-Green-Blue object that can be used to create images.
Usage
## S4 method for signature 'RasterLayer'
RGB(x, filename='', col=rainbow(25), breaks=NULL, alpha=FALSE,
colNA='white', zlim=NULL, zlimcol=NULL, ext=NULL, ...)
Arguments
x |
RasterLayer |
filename |
character. Output filename (optional) |
col |
A color palette, that is a vector of n contiguous colors generated by functions like rainbow, heat.colors, topo.colors, bpy.colors or one or your own making, perhaps using |
breaks |
numeric. A set of finite numeric breakpoints for the colours: must have one more breakpoint than colour and be in increasing order |
alpha |
If |
colNA |
color for the background ( |
zlim |
vector of lenght 2. Range of values to plot |
zlimcol |
If |
ext |
An |
... |
additional arguments as for |
Value
RasterBrick
See Also
Examples
r <- raster(system.file("external/test.grd", package="raster"))
x <- RGB(r)
plot(x, col=gray(0:9/10))
plotRGB(x)