1

I have two point shapefiles (start/destination) and one sort of street network shapefile. I would like a to create a distance matrix from the start-shapefile to the destination points, using the street network file. It does not necessarily have to be "shortest path", because mostly there is only one way anyway.

I am using QGIS 3.21 at the moment, but I have 2.18 also, so I don't really care on which one.

Is there a proper solution?

4

You can use the plugin QNEAT3 which is available for QGIS3. It offers multiple processing algorithms that produce origin-destination matrices (OD-Matrix) as line layer, table or csv file. It also supports m:n relations which fits to your two layers in your question. All algorithms rely on the dijkstra() method in the qgis.analysis module, therefore all costs are calculated on the basis of shortest paths.

You can get more information about the plugin at the qgis plugin repository and at the plugins documentation.

  • this plugin seems amazing but it is not clear to me what the units of output are when e.g. calculating an OD matrix (entry_cost network_cost exit_cost seem arbitrary somehow and even after experimenting with different cost fields i couldn figure out what it means). And there is no minimal working example that illustrates it. Do you have any info on that? (e.g. if i put in km/h as cost, what comes out?) – Fitzroy Hogsflesh Mar 18 at 21:26
  • Please refer to my answer on a similar ticket in the github repository: github.com/root676/QNEAT3/issues/12 – root676 Mar 19 at 20:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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