Skip to content
Prev 18374 / 29559 Next

Kriging and datum shifts

Thank you Mike,

I have indeed all the info that I need in the SPDF: lat, lon, CRS. The 
irregular distribution of data is not projection-related, but is 
prohibitive to using simple rasterization operations because source data 
and target cells do not always overlap. Hence the need for kriging (or 
some other form or interpolation). Rasterization would have made life so 
much easier... I will find a way, your suggestions are helpful.

As a though: I am just surprised to find that the sp package does not 
seem to notice that two global datasets with different longitude offsets 
entirely overlap. In my case, kriging the point dataset from -280 to +80 
lon to a raster from -180 to 180 lon leaves the raster data +80 and 
onward blank, while in fact the point dataset has provided data for the 
entire raster range - just at a different lon offset. It is an 
understandable but unfortunate shortcoming shared by many (GIS) toolkits.

I can work around this by modifying the longitude of the SPDF points:
     lon <- (lon + 180) %% 360 - 180
That is valid but rather hack.... Helmet time.

This leads me to a second issue: I suspect that when operating idw on a 
global dataset, interpolation is also not properly executed around the 
wrapping longitude boundary (e.g., I suspect that kriging is not applied 
to the boundary line at +180 for a raster that spans -180 to 180 
longitude, creating noticeable artifacts)

Best,
Jeroen
On 2013-05-27 6:03 PM, Michael Sumner wrote: