I have a problem with Map Algebra in ArcMap 10 to convert some codes made by VB, so I need to convert it to python to work in ArcMap 10 without problem.
How do I deal with map algebra in ArcMap 10?
the code:
con([Direction to univer] > 0 & [Direction to univer] <= 180,[Direction to univer] + 180,[Direction to univer] - 180)
asked Feb 16, 2011 at 5:52
1 Answer 1
You should be able to do the processing directly in python without much fuss:
import arcpy
from arcpy.sa import *
direction = Raster("direction-to-univer.tif")
output = con((direction > 0) & (direction <= 180), direction + 180, direction)
output.save("conned.tif")
answered Feb 16, 2011 at 6:04
Explore related questions
See similar questions with these tags.
default