[GRASS-user] Site in Polygon Query
Manuel Seeger
seeger at uni-trier.de
Wed May 23 11:27:06 EDT 2007
Jarosław Jasiewicz schrieb:
> Martin Wegmann napisał(a):
>
>> Hello Michael,
>>
>> On Wednesday, 23. May 2007 12:29:41 Michael Malicky wrote:
>>
>>
>>> Dear All!
>>>
>>> I am using GRASS for some time now, mainly for plotting distribution
>>> maps
>>> of plants and animals. Now a user came up with a different request:
>>> We have a map consisting of polygons and another one with sites. We
>>> need a
>>> query to filter all polygons that include at least one site. Is there a
>>> special command for this or a script ? Any help is welcome.
>>>
>>
>> just an idea:
>>
>> v.to.rast of polygons and sites (use=val)
>>
>> r.statistics method=sum and then r.mapcalc "output = if(map_sum >
>> 1,1,null())"
>>
>> regards, Martin
>>
>>
>>
>>
> Another simple idea
>
> v.to.rast of polygons with unique cats as raster value
> add column to points vector named 'poly_col'
> v.what.rast on new raster
>
> echo "count(*), poly_col, FROM your_point_table_name GROUP BY
> poly_col" |db.execute
>
> that all.
>
> Jarek
>
>
> _______________________________________________
> grassuser mailing list
> grassuser at grass.itc.it
> http://grass.itc.it/mailman/listinfo/grassuser
>
Hello all,
is not v.select the right command?
As I use it just today with ain=[polygon file] and bin=[point file] it
selects just the polygons where I find the points...
Manuel
--
Dr. Manuel Seeger
Wiss. Assistent Scientific Assistant
Physische Geographie Dpt. of Physical Geography
FB VI - Geographie/Geowissenschaften Geography/Geosciences
Universität Trier University of Trier
D - 54286 Trier
Tel.: +49-651-201 4557
Fax: +49-651-201 3976
Web: http://www.uni-trier.de/uni/fb6/geographie/mitarbeiter/Seeger/
More information about the grass-user
mailing list