Hi all,
I have lat and long information for 234 locations and I have shapefile of the route network. I am trying to obtain shortest path from each location to all other locations.
For instance for location 1, I would like to find shortest path from location 1 to 2, location 1 to 3, location 1 to 4 ....... location 1 to 234. I want to repeat this for each points.
I have tried to do this in ArcMap with OD cost matrix but the output was a straight line . I would like to obtain routes like I obtain by using "new route analysis".
Is there a way to obtain routes instead of straight line in ArcMap, or by using python?
Thank you so much !
Solved! Go to Solution.
By default the Closest Facility finds the 1 closest. As I mentioned in my previous post:
"make sure to set the number of facilities to find as 234"
You can set this CF layer property when you create it or through the layer properties dialog afterwards.
Jay Sandhu
Use the Closest Facility Solver. Load your locations as facilities and incidents and then make sure to set the number of facilities to find as 234. When you solve, you will get 234 by 234 routes with the geometry output as you expect from the route solver. The OD Cost Matrix is a similar tool but runs quickly as it does not spend the extra time writing out the detailed route geometry, and it is useful when you only need the shortest path costs.
Jay Sandhu
I tried to use Closest Facility Solver. I loaded 234 points as facilities and incidents. Since, " The closest facility solver measures the cost of traveling between incidents and facilities and determines which are nearest to one another, " I found closest facility to points becomes itself, then I could not have route network. ( I found routes like ; location 1 - location 1, location 2 - location 2 ...... location 234 - location 234 ). Am I missing something ? How I can use this tool to find 234 by 234 routes ?
Thanks !
Busra
By default the Closest Facility finds the 1 closest. As I mentioned in my previous post:
"make sure to set the number of facilities to find as 234"
You can set this CF layer property when you create it or through the layer properties dialog afterwards.
Jay Sandhu
Thank you so much ! This is so helpful !