I'm currently working with DEM rasters that I hillshaded. The data I received contain nodata borders, probably the footprint of the originial mosaic dataset. As I received them separately, I can't work on the footprint to delete the nodata lines. I'm trying to calculate the noData cells using the average value of the cells next to it, using raster calculator and this expression:

 Con(IsNull("DEM"), FocalStatistics("DEM", NbrRectangle(5,5, "CELL"), "MEAN"), "DEM")

The expression is working, but I'm losing quality of my hillshaded DEM. Do you know how I can avoid this?

Before raster Calculator

after raster calculator on the down DEM

After calculator on the down DEM

before raster calculator

  • ArcGIS 10.0 has been retired from service for years now. 10.x is every release of ArcGIS in the past two decades. Please provide the actual version you are using. The commands issues before the Con specified a resolution for operation. We'll need the code leading up to this line as well. – Vince May 8 at 18:13
  • I'm using the 10.5.1 version; I edited my question with this information. – Maja May 8 at 20:56
  • I'm not sure to understand which code to give you. I'm using the tool Raster Calculator and writing the expression into the "map algebra expression" and I don't see where I can specify the resolution. – Maja May 8 at 21:02
  • So the the pixel size will be determined by the environment rules, which probably specifies the largest pixel of inputs, for which you have a function returning pixels 5x of the original. – Vince May 8 at 21:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.