Given a raster object, an extent, or a bounding box, a raster of with square cells and having the
extent and number of cells specified is returned.
Usage
squareRaster(x, cells=NULL)
## S3 method for class 'RasterLayer':
squareRaster(x,cells=NULL)
## S3 method for class 'BasicRaster':
squareRaster(x,cells=NULL)
## S3 method for class 'matrix':
squareRaster(x,cells=NULL)
## S3 method for class 'Extent':
squareRaster(x,cells=NULL)
## S3 method for class 'SpatialPoints':
squareRaster(x,cells=NULL)
## S3 method for class 'SpatialPointsDataFrame':
squareRaster(x,cells=NULL)
## S3 method for class 'SpatialPolygons':
squareRaster(x,cells=NULL)
## S3 method for class 'SpatialPolygonsDataFrame':
squareRaster(x,cells=NULL)
Arguments
x
A bounding box from a
SpatialPoints or SpatialPolygons object or an
Extent from a Raster.
cells
The number of cells in the x direction. If NULL the number of columns of x is used.