[GRASS-user] v.vect.stats has no results

Markus Metz markus.metz.giswork at googlemail.com
Tue Oct 18 05:43:11 EDT 2011


On Tue, Oct 18, 2011 at 9:45 AM, Andres Kuusk <andres at aai.ee> wrote:
>
>
> Hi!
>
> What I am doing wrong, or is this the problem of v.vect.stats?
>
> I have an area vector "area_vector" of three rectangular areas and a vector
> "point_vector" with numerous points inside these areas.
> The output of the command
>
> v.vect.stats -p points=point_vector areas=area_vector type=point player=1
> alayer=1 method=average pcolumn=uav8 ccolumn=nuav scolumn=uav8mean --verbose
>
> is empty. No error messages.
>
> The areas in the area_vector have categories 1, 2, 3.
> The column uav8 is present in the table point_vector and I can see the
> values of attributes making query in display window.
> GRASS is using Postgres, driver pg. Attribute values are real.
> v.rast.stats is working and updates attribute table.
>
> Can the problem be that the point_vector has no column 'cat'? The key column
> for linking the vector layer to its attribute table has a different name.
>
No, v.vect.stats uses the key column recorded in the db link info. If
there would be a problem with the points vector, v.vect.stats should
print something like

area_cat|count|average
1|0|null
2|0|null
3|0|null

> I am using GRASS-7, r47868.

Maybe rebuilding topology helps? Also output of v.info on the area
vector and v.vect.stats after g.gisenv set="DEBUG=2".

Markus M


More information about the grass-user mailing list