I have two raster, Raster1 ( ~1km resolution ) and Raster2 (90m resolution). There are about 100 pixels of Raster2 under a pixel of Raster1. I would like to calculate range (max-min) of those 100 pixels of Raster2 for each pixel of Raster1.
I tried zonal statistics, which accumulated the range values for each value of pixel NOT for each pixel, which I don't want.
I appreciate any clue how to do this.
Many thanks in advance.
Solved! Go to Solution.
The OP mentioned stat Zonal Statistics does not work since values of pixels in 1km raster repeat and the statistics for each pixel is required. Aggregate allows you to do this, although you will need to run MINIMUM and MAXIMUM separately and use Raster Calculator to calculate the difference.
Regiongroup first, is what I normally do first, if there is any chance of duplication of zones (akin to multipart to singlepart in vector). I don't like multipart anything and rasters do this by default. So if the 1km raster values repeat, I would instinctively regiongroup before I proceeded (if I was using SA and not arrays anyway.)
I suggested ZonalStatisticsAsTable for this reason the ambiguity issue is mentioned in the help files. Plus the multipart nature of a 'zone' can lead to different results for 'majority' and 'minority' since distinctly separate areas belong to the same zonal class may not exhibit similar properties because of the zone aggregation
....."or majority and minority calculations, when there is a tie, the output for the zone is based on the lowest of the tied values"...
I generally don't like zones or multipart anything unless you know what you are dealing with, but it may be a workflow preference
Thank you Xander and all.
it is solved now.
As suggested by Xander, I used the Aggregate tool to evaluate minimum and maximum first, then I used Raster calculation to calculate range (Max - Min).
Appreciate your time.