0

In ArcGIS 10.2 I have 2 rasters A and B. A cover a certain study area while B represent a "cities mask" obtained by rasterising a shapefile. All the cells of B have a 0 value. The resolution of A and B is the same. I simply want A's cells to have a value of 0 when they match with B's cells. I have tried using the conditional function in the raster calculator [ Con(B=0,"B","A")] and setting A as "snap raster" in the environmental settings, but the output raster is always equal to B. I also tried to multiply AxB setting A as "snap raster" but again the result is B. What am I doing wrong?

  • Set extent to bigger one (A?). Calculate B. Use Con() on A and Bb – FelixIP Feb 14 '17 at 17:13
  • @FelixIP, I have have tried setting A (the bigger) as processing extent in the environmental variables and I computed the formula Con(B=0,"B","A"), do you know if a statement does exist that allow to say "where B does (or does not) exist" or "where B overlaps A"? Could you please tell me which formula you mind to use? – Lollo Feb 15 '17 at 8:34
  • You missed second point in my comment. It will expand B. Use Con for A and expanded B. If a not completely inside b, mosaic them to new raster c. Use c to expand a and b – FelixIP Feb 15 '17 at 9:03
  • Also b==O no single = – FelixIP Feb 15 '17 at 9:11

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.