Dear Paul and Edzer,
Thanks a lot for your answers.
Before reading the solution proposed by Paul, I had tried with:
# reading the boundary of the catchment
library(maptools)
catchment <- readShapePoly("only_catchment.shp")
catchment.grid <- spsample(catchment, cellsize=100, offset = c(0.5,
0.5)) # reading the boundary of the catchment
and then I did an IDW interpolation with:
pp.idw <- krige(PP_DAILY_MEAN_MM~1, meteo, catchment.grid)
and it works.
However, after reading your solution, I realised that I didn't use the
command:
gridded(catchment.grid)
but I got an interpolation anyway.
Where is performed the interpolation when I don't use a gridded grid (
gridded(catchment.grid) ) ?
it is actually
gridded(catchment.grid) <- TRUE