Skip to content
Prev 25433 / 29559 Next

spsample: defining the size of the cell in an hexagonal grid

Dear list members,

How can I define the size in hectares of the cell when doingan hexagonal
grid with the function spsample.  What it means "cellsize"?  I want to
create cell sizes according to some specific number of hectares.  How can I
do it?


data(meuse.grid)
gridded(meuse.grid) = ~x+y
plot(meuse.grid)
HexPts <-spsample(meuse.grid, type="hexagonal", cellsize=1000)
HexPols <- HexPoints2SpatialPolygons(HexPts)
plot(HexPols[meuse.grid,], add=TRUE)