2

My raster is in the GRID format, source type is continuous and pixel type is floating point (32bit).

If i use the raster calculator ("dem" *1000 or "dem >= 2m" (to highlight certain heights) it gives me the following error:

ERROR 000539: Error running expression: rcexec() : No module named collections.

3
  • 1
    Perhaps this post might help: Error: ERROR 000539: Error running expression: rcexec()
    – Joseph
    Commented Jun 29, 2016 at 12:53
  • Dear Joseph, thank you very much for your response. I found this page earlier. I am not into Python. Do I understand it correctly, that I have to use it because of my input raster data? Is there no other chance to run the calculator as usual?
    – Jonnus90
    Commented Jun 29, 2016 at 13:01
  • Apologies but I haven't come across this issue before, hopefully others can advise =)
    – Joseph
    Commented Jun 29, 2016 at 13:09

1 Answer 1

1

I am not sure what are you going to extract from the following formula because it is strange. The formula says multiply the elevation of the DEM by 1000 OR if the DEM values are more than or equal to 2m it will output 1 where the condition is met, and 0 if the condition is not met (thanks to Luke for his clarification), which does not make sense.

But the expression is incorrect, you should write the formula like this:

"dem" * 1000 | "dem"  >= 2

| : means OR. Check the Raster Calculator Help for correct operators in the Raster Calculator tool dialog box.

If you want to extract DEM values that are more than or equal to 2m you can use SetNull() to set the DEM values that are less than 2 to NULL and keep the values that are more than or equal 2m as follows:

SetNull("DEM" < 2,"DEM")
0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.