R based Delaunay Triangulation Function for PostGIS using the deldir package
This article shows how to create and use an r-based Delaunay triangulation function for postgis using a XYZ supporting version of the deldir package.
This article shows how to create and use an r-based Delaunay triangulation function for postgis using a XYZ supporting version of the deldir package.
It is useful to have functions for converting from individual degrees, minutes and seconds to a single decimal degree value and back again. Here are some useful plPgSql functions. DMS2DD Firstly, a function to convert individual degrees, minutes and seconds values to a single decimal degree value. Now for some examples…. Result: dms2dd -44.1805555555556 Result:Read More
Recently I had need to convert a PL/SQL Oracle Spatial function I created years ago called FindCircle to SQL Server 2008 for use in another project. That function was original work already released to the public domain as part of my free COGO package for Oracle. Here is that function for SQL Server. Note thatRead More
A common question that comes up in the various database forums (PostGIS, SQL Server, Oracle) is how to “grid” a linear or polygonal object. By “grid” one means work out the square pixels (rectangular polygons) that cover or define a vector geometry. Here is some SQL for doing this for PostGIS. Single Geometry The followingRead More
Many people have asked me to convert my Oracle Parallel function to PostGIS. I did it a year or so ago but the results were not as I wished. I have now corrected much that was wrong with the function so I hope it is of more value to those who have asked for itRead More
In my article on the creation and use of a space keys for the spatial sorting of spatial data, I show how to implement a Morton key for PostgreSQL/PostGIS pl/pgSQL. The function is as follows: Now, let’s test it with some simple SQL: Results I hope this is of use to someone.
Implementing Point-based Costs in pgRouting pgRouting is a great tool but it does have certain limitations. One limitation is that one cannot have costs at specific nodes. All costs have to be edge based. Discussion on Node/Edge Costs in pgModeler For example, suppose a network has a stop valve between two pipes. Normally the stopRead More
“Imitation is the Greatest Form of Flattery” Before I talk about SSMS, pgAdmin and DBeaver spatial visualisation solutions, some history about the first spatial tool that extended a (non-GIS) database management and development tool: GeoRaptor. GeoRaptor History Many years ago a visionary programmer added spatial capabilities to SQL Developer 0.9, calling his extension GeoRaptor (theRead More
The people over at the Free and Open Source Software Learning Centre on 19-22nd May 2009 hosted an event that included three sessions on PostGIS (on 21st May): Steve Singer, OpenStreetMap with PostGIS ; Regina Obe and Leo Hsu, Spatial Analysis with PostGIS ; Luis Bueno, Saving the Amazon with PostGIS . They are worthRead More
I find having a vectorising function in my database kit-bag almost indispensable in my work. I have written and revised my Oracle PL/SQL functions that do this many times over the years and so, when I first started using PostGIS, I decided to learn how to program in PL/pgSQL by implementing something familiar: a GetVector()Read More