Hi Chris,
thanks for your suggestions!
The data is in Shapefiles, I do not have a PostGIS installation at hand...
What you mention is indeed what I am looking for - some statistical parameters (mean, count, min, max) of the points that fall into a polygon counting only the points that have the same direction attribute as the polygon.
I will try with virtual layers.
Regards,
Roland
Gesendet: Mittwoch, 9. Juli 2025 um 15:28
Von: "chris hermansen" <[email protected]>
An: "Roland Spielhofer" <[email protected]>
CC: qgis-user <[email protected]>
Betreff: Re: [Qgis-user] Join attributes by location (summary) with condition
Roland and liat
On Wed, Jul 9, 2025, 01:33 Roland Spielhofer via QGIS-User <[email protected]> wrote:
Hi,I am trying to get mean values from points lying inside polygons - that would be easy with "join attributes by location (summary)".But: I have overlapping polygons - coming from road segments (motorways with separate lines per direction). The points and the polygons have a common attribute ("+" or "-" per direction) .I want to summarize the points of one direction that are lying inside the polygon of the same direction.Is there a way to achieve this?
Are you able to use SQL?
This is a straightforward query in (for example) PostGIS, which offers spatial comparison operations such as "within"
So if you select polygons and join the points using ST_within you can (for example) use GROUP BY and (for example) AVERAGE to get the average value of some attribute for all points within each polygon.
Is this the kind of thing you are looking for?
_______________________________________________ QGIS-User mailing list [email protected] List info: https://lists.osgeo.org/mailman/listinfo/qgis-user Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
