[GIS] Calculating average slope along line using ArcGIS Desktop

arcgis-desktoparcmaparcpyslope

I have a slope layer and I want to calculate the average slope along a line. This line isn't necessarily straight (e.g its a route, I would like to be able to input geographic coordinates along that line and have a script that outputs the average slope). Is this possible?

Best Answer

A simple approach that you could automate in ArcMap using Python would be to break your line into points at a chosen interval or even just at the vertices. Then extract values to points from the raster to get the longitudinal profile (make sure to select the interpolation option). Then simply calculate the average value of those points.

As @whuber mentioned there is an accuracy trade-off with simplicity, but if you're looking for a simple solution that you could script quickly the above should help.