Select to view content in your preferred language

Problem with cost distance

597
1
10-05-2011 08:15 PM
YinghuiCao
Deactivated User
Hi, I am trying to calculate a distance surface where for each cell, it will return the shortest transportation to ports, including shortest Euclidean distance to the roads, and then the shortest distance to a port along the road network.

There are a range of ports so the I am trying to use the cost distance tool to calculate the network distance from each road cell to the cloest port, by using a cost surface containing only road cells with the value of 1 (equal weight).

The output is also cells along the road only, however, I found the output cells are not 100% overlaying the input road cells. It looks like it is resampled. The problem is that, it is only using one port location as the source. I would expect the tool to choose the closest port for different cells.

I noticed that because of the resampling problem, some of the ports are not within the output raster cells any more. Is it a reason for the cost distance tool not identifying these ports as source locations? But for those ports that are still within the output cells, they are not used as the source as they should, either. So does anyone know what is the issue here?
0 Kudos
1 Reply
DaveGalbraith
Emerging Contributor
I'm guessing it's a default environment setting that's causing you grief.  The alignment issue can be resolved by setting the snap raster, but I'm not sure about the extent problem (see the settable parameters after expanding the 'processing extent' portion of the environment settings in v10.0).  It could also be the analysis extent/mask that's settable in the 'raster analysis' setting.

There is a way to change the default environment settings, but it is buried pretty deeply within clicki-nested-GUI interfaces that are renamed and relocated with exciting new icons with every change in version/service pack etc.  Also, watch out, because sometimes tools that are called by the same name from one version to the next, or even within a version but accessed by different methods, can do fundamentally different things to your data and require subtly different data types or file structure conventions.

Good times?
0 Kudos