2

In QGIS, I have a set of points from which I created a series of voronoi polygons. I also have a set of circumferences created from another points, like this:

enter image description here

I need to identify which voronoi polygons are cut by which circumferences (one polygon would appear in more than one circunference, so I need to track de attributes), but everything I have seen is about intersection.

Bonus points would be polygons with only area > N, but I need to start somewhere.

EDIT:

First solution Joseph gave me in the comments gave me the polygons which intersected with the circumferences as a whole, in a similar fashion to wiltomap. The actual answer from Joseph worked for me.

As an extra, from the anwer I was able to calculate the polygon area which allows me to filter those with a very small one.

Rwak
  • 123
  • 3
  • Are polygons used in your circumference layer? If so, I would probably convert these into lines (Vector > Geometry Tools > Lines to Polygons) then either run Intersection (Vector > Geoprocessing tools > Intersect) or Join attributes by location (Vector > Data Management Tools > Join attributes by location). If you wanted, you could join the result attributes back into the voronoi polygon layer using the JOINS option (Layer Properties > Joins) or Join attributes table from the Processing Toolbox. – Joseph Nov 17 '15 at 13:07
  • Thank you Joseph, join attributes by location worked! Well, almost. Now I am aware that my problem is a bit trickier. That option gave me a joined layer with the intersection of both circumferences and polygons. What I actually need, is kinda the same, but for each circumference. I'm not sure if there's an easy way for that since I have a LOT of circumferences. – Rwak Nov 17 '15 at 14:29
  • If you need to select polygons that are either inside or outside buffers, then see my answer. If you need to bring back attributes from Voronoi polygons to buffers, then Rwak and Joseph suggestions are fine. But you don't say anything about attributes need, do you? – wiltomap Nov 17 '15 at 15:30
  • 1
    Well joseph that one actually worked, thanks! Wiltomap I have posted a comment in your anwer also. I'll update the question to be more clearer. – Rwak Nov 17 '15 at 15:46
  • @Rwak - Awesome buddy, will post the above comment as an answer for the convenience of others :) – Joseph Nov 17 '15 at 16:00

2 Answers2

2

Try using Spatial Query tool through Vector > Spatial Query menu:

  • Select the Voronoi polygons layer as source features
  • Select Intersects option in the dropdown list
  • Select the buffers layer as reference features
  • Apply

You then get Voronoi polygons that intersect the buffers (either within and without buffers). You can save this selection by right-clicking on the Voronoi polygons layer and select Save As... (don't forget to click Save only selected features option!).

wiltomap
  • 2,690
  • 2
  • 22
  • 52
  • Thank you wiltomap. I'm afraid I'll have to update the question because indeed I need the attributes, but only because I need to identify which circumferences intersect with which polygons (meaning the polygon ID will be duplicated in some cases). In any case the Spatial Query plugin helps me with another issue, so thanks a lot! – Rwak Nov 17 '15 at 15:44
  • Union geoprocessing tool should do the job, then... Let us know if you have found a solution. – wiltomap Nov 17 '15 at 15:57
1

Great answer by @wiltomap.

Perhaps not an ideal solution but you could use Union (Vector > Geoprocessing Tools > Union). Select the circumference layer as your input layer and voronoi as your union layer. Go to the Attributes Table of the output and select a field which originally belonged to the circumference layer.

Reorder this field in ascending/descending order, what you should notice are values in that field with NULL. Delete this rows (use Shift + left click on first and last row). Hopefully, you'll be left with circumferences with intersected polygons with all corresponding attributes.

Hope this helps!

Joseph
  • 75,746
  • 7
  • 171
  • 282