2

In QGIS I have a layer of points each one representing a household with its (x, y) coordinates and a population assigned to them. I'd like to calculate the points that are accessible from each point as a proxy to estimate the perceived density of that point.

Distance matrices are not the most optimal solution because they do not take into consideration the urban morphology and physical barriers surrounding the household.

I've tried using the ORS Tools plugin, but the number of points that I have (around 2000, so more or less 2 million evaluations) largely surpasses the limits of their calculation capacity.

Here's some screenshots of my working material:

enter image description here

enter image description here

The map underneath the point layer was just there for the sake of clarity. I do have a vector of the street network, but I don't know how to use it to build a time matrix (I'm new to QGIS, so any help will come in handy)

Here's a picture of the network + datapoints:

enter image description here

3
  • 1
    It look like your underlying map is a raster. I don't think any algorithm would be able to extract barriers or thoroughfares out of this without a vector representation. The you could at least constrain travel on the network of lines. Commented Apr 10, 2022 at 23:53
  • @LeighBettenay oh sorry the map underneath was just for clarity. I have the vector for the street network, but I don't know how to use it to calculate the walking distance between every pair of points (I'm kind of new to GQGIS).
    – Marc
    Commented Apr 11, 2022 at 0:11
  • 1

1 Answer 1

1
  1. Run Menu Processing > Toolbox > Shortest path (point to layer) in Batch mode. Like this, you can automatically run it separately for each of your 2000 points.

  2. To add each start point, select Autofill... > Add values by Expression... and insert this expression: aggregate( 'points', 'array_agg', $geometry), where points is the name of your points layer.

  3. Use Autofill... > Fill down for the other settings (for time matrix, use fastest setting). For Vector layer with end points, again use your points layer as input to get the shortest/fastest distance.

Output is a separate line layer for each point feature, connecting it along the shortest/fastest path along the network to all other points. In the attributes, you get a cost field with the distance or time to reach each destination so you can filter out distances/times longer then the maximum you'd like.

To get all resulting layers on one layer, use Menu Processing > Toolbox > Merge vector layers.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.