I'm currently using ArcGIS 10.2.2 (Advanced).
I need to generate a new raster from an existing raster by comparing the cell values to a list where an new cell value will be listed against the old value.
The existing unique list of values:
The new cell values are:
- 1 - 1
- 2 - 8
- 4 - 7
- 8 - 6
- 16 - 5
- 32 - 4
- 64 - 3
- 128 - 2
I'm looking for advice in how I can achieve creating a new raster based on comparing the existing cell values and replacing them with the new cell values using python. I could create a map algebra function to achieve the following using if statements, but feel that there should be a better method using Python. I was wondering if numpy arrays to achieve the following is suitable, but I have used them before so any help in getting started will be appreciated. Any other methods using python are also welcome.