[postgis-users] ST_SelectByValue
David Haynes
haynesd2 at gmail.com
Thu Jun 5 12:33:52 PDT 2014
reclass would allow me to change the values of the pixel.
"ST_SelectByValue" is supposed to like a map algebra or in ArcGIS Terms
select by attribute.
On Thu, Jun 5, 2014 at 1:38 PM, Pierre Racine <Pierre.Racine at sbf.ulaval.ca>
wrote:
> Try ST_Reclass().
>
> > -----Original Message-----
> > From: postgis-users-bounces at lists.osgeo.org [mailto:postgis-users-
> > bounces at lists.osgeo.org] On Behalf Of David Haynes
> > Sent: Friday, May 30, 2014 10:49 AM
> > To: postgis-users at lists.osgeo.org
> > Subject: [postgis-users] ST_SelectByValue
> >
> > Hello,
> >
> > I am fairly new to using rasters in postgis, but I am wondering if there
> is a
> > faster way to extract values from categorical rasters (e.g. landcover
> types)
> > than using map algebra. In the PostGIS in Action book, pg 404 has a
> > function called ST_SelectByValue(raster|geometry, 'expression') which
> > seems to incorporate map algebra, however I can't seem to tell if this
> > function is finished and available in postgis as I get an unknown
> function
> > error.
> >
> > My version is this.
> > "PostgreSQL 9.3.2 on x86_64-unknown-linux-gnu, compiled by gcc
> > (Ubuntu/Linaro 4.6.3-1ubuntu5) 4.6.3, 64-bit POSTGIS="2.1.1 r12113"
> > GEOS="3.3.3-CAPI-1.7.4" PROJ="Rel. 4.7.1, 23 September 2009"
> > GDAL="GDAL 1.9.0, released 2011/12/29" LIBXML="2.7.8" LIBJSON="UN
> > (...)"
> >
> >
> > And I found a webpage
> > http://trac.osgeo.org/postgis/wiki/WKTRaster/SpecificationWorking03
> >
> > search for "ST_SelectByValue" at the bottom, indicating that it was
> finished.
> >
> >
> > AAccomplished Objectives
> > <http://trac.osgeo.org/postgis/wiki/WKTRaster/SpecificationWorking03#A
> > ccomplishedObjectives>
> >
> >
> > ST_ValueCount(raster, value) -> integer - done see below
> >
> > ST_ValuePercent(raster, value) -> double precision - done see below
> >
> > ST_Resample(raster, method, originx, originy, pixelsizex, pixelsizey) ->
> raster
> > - done see below
> >
> > ST_SelectByValue(raster, 'expression') -> same type as first argument
> >
> > ST_Clip(raster|geometry,geometry) -> same type as first argument
>
> _______________________________________________
> postgis-users mailing list
> postgis-users at lists.osgeo.org
> http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20140605/8fc334b4/attachment.html>
More information about the postgis-users
mailing list