5

I have created a uniform (nominally square) gird of polygons using the grid tool. I have a road network layer that consists of lines. What I would like to do is iterate over the grid polygons and clip the road network within each square. I can certainly clip the road network out using a single polygon but I would like to automate the process :-) (160+ polygons in the grid!).

Happy to use QGIS 2.14 or 2.18!

1 Answer 1

6

You need to use clip tool, from Processing toolbox -> QGIS geoalgorithms -> Vector overlay tools -> Clip, as follows:

enter image description here

Select the roads as input layer and grid as clipping layer, and select the green arrow beside the clipping grid

enter image description here

The output will be clipped roads based on each grid polygon.

enter image description here

enter image description here

3
  • My version of qgis doesn't have the 'Vector Overlay Tools' option in Processing->Geoprocessing (neither 2.18.3 or 2.14.11). Where do they come from? Commented Feb 27, 2017 at 0:10
  • Ok. Fixed. Had to remove ~/.qgis2. Menus got messed up when installing new version... Commented Feb 27, 2017 at 0:40
  • 1
    @GlennGeers - Don't forget to accept this answer by clicking the green-faded tick on the left-hand side of this post :) Commented Feb 28, 2017 at 14:01

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.