Skip to content
Prev 10313 / 29559 Next

Step characteristics on raster maps

Dear list members,

Sorry if I didn't replied earlier, but here is the solution I finally
used. Thanks to Pierre Racine who helped us, I installed a PostgreSQL
data base, with PostGIS and WKTRaster [1]. WKTRaster allows to handle
raster maps in addition to all vector classes already supported by PostGIS.

In the end, after the import of trajectories within the db (via ltraj >
SpatialLinesDataFrame > Shapefile > DB, but there might be easier
solutions), it is relatively easy to get the overlay of the trajectory
with raster maps, after some SQL learning. With this approach, it is
actually possible to split each segment into smaller segments according
to the underneath pixels. In the end, it is thus possible to get the
exact proportion of each segment regarding the underlying map. And the
process is incredibly fast (compared to pure R code or ArcGIS).

The only current drawback is that WKTRaster can handle only integer
maps. The workaround for continuous maps is to scale it, e.g., between 0
and 100 to get enough information with the integer part of it. WKTRaster
is still under heavy development, and this should be fixed in the future.

Hope this helps other people interested!
Mathieu Basille.


[1] http://trac.osgeo.org/postgis/wiki/WKTRaster



Le 30/09/2010 08:46, Mathieu Basille a ?crit :