make.rasbox | R Documentation |
Rasterize a spatial structure returns either a raster or cell matrix based on a spatial box structure
make.rasbox(boxes = box11, rrow = 26 * 5, rcol = 29 * 5, raster = T)
boxes |
spatial polygons |
rrow |
number of rows for output |
rcol |
number of columns for output |
raster |
Logical. If False, returns a matrix |
a raster or matrix
par(mfrow = c(3,1))
data(box11)
r = make.rasbox(box11)
m = make.rasbox(box11, raster = F)
plot(box11, border = 2); world(add = T)
plot(r); world(add = T)
world(add=F); image.plot(m$lon, m$lat, m$box, add=T)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.