Find actual distance of lowest-cost path using 'cost distance' tool

676
2
06-08-2017 02:47 AM
WilliamZappa1
New Contributor

Hi,

Does anyone know how to find the actual distance of the lowest-cost path produced using the 'cost distance' tool (or another tool), rather than the calculated 'cost distance'?

For example I'm looking at Italy, and I want to find shortest land distance from each raster cell to the center of the country, only crossing water if it is absolutely necessary (e.g. from islands). So, I defined a base cost raster with land cells given a low value (1) and offshore cells given a higher value (5). Then, I used the 'cost distance' tool to calculate the least accumulative cost distance from each cell to the center (source). As a result, values of the cost distance raster on island cells are much higher than on the mainland as they include the additional cost of having to go across the water - but I want the actual (horizontal) distance. I don't want to set the offshore cost as 1, as then it would cause short-cutting through water in other areas (e.g. the boot). I also don't want to use the Euclidean distance tool and set offshore cells as NA, as then I can't include islands. (Note the approach should be scalable as I want to apply it to multiple countries, not just Italy).

Thanks!

Example

0 Kudos
2 Replies
XanderBakker
Esri Esteemed Contributor

Normally after running the Cost Distance—Help | ArcGIS Desktop tool  (creating the optional backlink raster) you would continue with the Cost Path—Help | ArcGIS Desktop  tool to create the minimum cost path. This raster can be converted to vector using Raster to Polyline—Help | ArcGIS Desktop and if you write your result to a file geodatabase you would have an attribute Shape_Length that holds the length for each polyline. 

DanPatterson_Retired
MVP Emeritus

If you skip the modelbuilder stuff, what Xander Bakker‌ is talking about is exemplified in a lesson on costdistance ... at least the visuals may clarify.