Solved! Go to Solution.
"If something is hard you should just give up, since it probably wasn't worth doing it in the first place."
pointDict = {} pointFcList = ["tower_1.shp","tower_2.shp","tower_3.shp"] for pointFc in pointfcList: searchRows = arcpy.da.SearchCursor(pointFc, ["SHAPE@XY","DISTANCE"]) towerId = pointFc.split("_")[-1] for searchRow in searchRows: xyKey, distance = searchRow if xyKey not in pointDict: pointDict[xyKey] = [(distance, towerId)] else: pointDict[xyKey].append((distance, towerId)) for keyKey in pointDict: pointDict[xyKey].sort()
but how do I do this? the euclidean distance only shows how far it is to the closest turbine and doesn't give me any idea which turbine it is...
But I need the ID to the closest, the second closest, the thrid closest and so on.
How about making a euclidean allocation grid for the 1st closest, then another one for the 2nd, 3rd, etc.. Then use the combine tool to basically union all the euclidean allocation grids?
Maybe it would just be easier to make a bunch of seperate viewshed rasters and then combine them together.... then cursor through the table and work out some sort of scoring system.
VIEWSHED_1 VIEWSHED_2 VIEWSHED_3 0 1 1 0 2 0 0 3 0