Skip to content

Best approach to implement Spatial Interpolations

5 messages · Cesar Martinez Izquierdo, ONKELINX, Thierry, Edzer Pebesma +1 more

#
Hello list,
we are trying to implement spatial interpolations (IDW and several types 
of  Kriging) in our open source GIS application, which is written in Java.

We plan to use JRI to connect with R from Java, and then use the 
features of "gstat" R-package to calculate the interpolations.

However, we don't want R to draw the results of interpolations, we just 
want to get the raw result which we will draw in our GIS client.

Now, the questions:
- Do you think gstat is the best R package for this task?
I've read that it doesn't allow not-projected data. Is there a package 
which provides similar algorithms and works with not-projected data?

- Do you have some documentation regarding this topics (more exactly: 
documentation about how to get the results of a kriging, etc with JRI)?

Any comments and suggestions are welcome.

Regards,
#
Dear Cesar,

Krige, idw of predict.gstat all return objects with the prediction. You only get maps when you plot these objects. So you only need to find out how to return these objects with JRI to your GIS.

Edzer Pebesma will be best positioned to answer your question about gstat's capability on working with non-projected data.

Cheers,

Thierry

----------------------------------------------------------------------------
ir. Thierry Onkelinx
Instituut voor natuur- en bosonderzoek / Research Institute for Nature and Forest
Cel biometrie, methodologie en kwaliteitszorg / Section biometrics, methodology and quality assurance
Gaverstraat 4
9500 Geraardsbergen
Belgium
tel. + 32 54/436 185
Thierry.Onkelinx at inbo.be
www.inbo.be 

Do not put your faith in what statistics say until you have carefully considered what they do not say.  ~William W. Watt
A statistical analysis, properly conducted, is a delicate dissection of uncertainties, a surgery of suppositions. ~M.J.Moroney
#
Cesar Martinez Izquierdo wrote:
As the author, I will refrain from commenting on this. It has a large 
user base, a code that has been open source and stable for a long time, 
and it has several options not found in other packages, notably block 
kriging, cokriging, and kriging in a local neighbourhood with an 
efficient search algorithm (quadtrees) for huge/massive data sets.
Recently, this functionality has been added, only the quadtree algorithm 
does not work in this case; I'm still in doubt whether quadtrees are 
useful on a sphere. Consider this code somewhat experimental, but I'm 
willing to help debug it if needed. It does, for example not check 
whether covariance functions provided are positive definite on a sphere, 
and has little (if any) functions specifically dedicated for this 
purpose. It does compute great circle distances though.

Another package that seems to deal with unprojected coordinates that you 
may want to look into is package fields.
Perhaps the JGR user interface is an example?

I'm very interested in your developments and experiences; please keep 
me/us updated on this mailing list.
--
Edzer
#
Edzer,

Not to deflate Cesar's project, but from our past email exchanges you 
are aware that I have been very pleased with the standalone version of 
your gstat program and feel that it interfaces wonderfully with GRASS 
6.x; I would highly recommend this approach to anyone. Also, for those 
who may not be aware, use of the R gstat package is usable with GRASS 
GIS as well. This is not to say that the gstat-GRASS interface employs a 
modern GUI; it does not, but the interface is straightforward and very 
usable.

I also look forward to seeing the results of Cesar's development project.

Regards,
Tom
Edzer J. Pebesma wrote:

  
    
#
Edzer J. Pebesma escribi?:
Thanks to everyone for the information.
Following your advices, we have finally decided to use JRI+R+gstat.
You will have some news when there is something to show.
And maybe we drop some more questions here in the meantime...

Regards,