change multiple rasters with one Con statement

345
2
01-02-2012 04:51 AM
MattiasVan_Opstal
New Contributor
Hi everyone!

Does anyone know if it is possible to change several rasters with one Con statement?
I am currently doing something like this:
x = Con(statement, x*2)
y = Con(statement, y*3)

But since I work on very large rasters I guess it would be more efficient if I could do something like this:

x,y = Con(statement,x*2 & y*3)

Is this possible?

Kind Regards,
Mattias
0 Kudos
2 Replies
DanPatterson_Retired
MVP Emeritus
You can only process one raster as output at a time
0 Kudos
MattiasVan_Opstal
New Contributor
Thank you!
The code will look little bit messy now, a lot of times the same condition in a condition in a condition,... for each output raster. But thank you anyway.

Mattias
0 Kudos