I want to write a function which takes in two arguments (from two rasters) and compare those 2 values against a set of hard coded pair values inside function. Then return a value which i want to use to generate a new grid. I am not quite there to complete the function. Any suggestions?
def grid(val1, val2):
table = {'10','1':'75','10,2':'75','10,3':'83','10,4':'87'}
for i, j, k in table.iteritems():
if val1 == i:
if val2 == j:
val = k
return val
t = grid(10,1)