[R-sig-Geo] group data into squares
Luis Ridao Cruz
Luisr at frs.fo
Wed Nov 29 12:40:25 CET 2006
R-sig-geo-help,
I have locations of fish abundance
which I want to aggregate into squares.
The code below creates the grid:
library(sp)
test <- GridTopology(c(-10.5,60),c(0.1,0.1),c(67,35))
coordinates(test)
coordinatevalues(test)
yy <-SpatialGrid(grid=test)
plot(yy,pch=16,cex=0.3,col=1)
and within each cell the total abundance of fish
should be specified.
How can I do this?
Thanks in advance
> version
_
platform i386-pc-mingw32
arch i386
os mingw32
system i386, mingw32
status
major 2
minor 4.0
year 2006
month 10
day 03
svn rev 39566
language R
version.string R version 2.4.0 (2006-10-03)
>
More information about the R-sig-Geo
mailing list