I am running an OD Cost Matrix in ArcGIS Pro for the very first time. I noticed that there is no option for cost accumulation in Pro in contrast to ArcMap! Is there a workaround to be able to have the impedance as "Time" and be able to report "Distance" as well in Pro?
Solved! Go to Solution.
Hello Majid. The accumulate attributes option is not currently available from the UI in Pro, but you CAN use it. The easiest way is to use the Make OD Cost Matrix Analysis Layer tool to create your OD cost matrix layer rather than using the Network Analysis drop-down on the Analysis tab. This tool has an option for accumulating attributes (note that this option is not available if you're using ArcGIS Online or a portal service as your network data source).
You can also modify an existing layer's accumulate attributes using the solver properties object in the python window, like this:
doc = arcpy.mp.ArcGISProject('current')
mapObj = doc.listMaps()[0]
layerObj = mapObj.listLayers('OD Cost Matrix')[0]props = arcpy.na.GetSolverProperties(layerObj)
props.accumulators = [<list of attributes you want to accumulate>]
Hello Majid. The accumulate attributes option is not currently available from the UI in Pro, but you CAN use it. The easiest way is to use the Make OD Cost Matrix Analysis Layer tool to create your OD cost matrix layer rather than using the Network Analysis drop-down on the Analysis tab. This tool has an option for accumulating attributes (note that this option is not available if you're using ArcGIS Online or a portal service as your network data source).
You can also modify an existing layer's accumulate attributes using the solver properties object in the python window, like this:
doc = arcpy.mp.ArcGISProject('current')
mapObj = doc.listMaps()[0]
layerObj = mapObj.listLayers('OD Cost Matrix')[0]props = arcpy.na.GetSolverProperties(layerObj)
props.accumulators = [<list of attributes you want to accumulate>]
Hi Melinda - Thanks for the response. I actually find out about OD Cost Matrix Analysis Layer tool myself as well. Hopefully, the documentation and UI would be upgraded regarding this.
Thanks for the Python code, really helpful.