Tag Info

New answers tagged


A simple method is: mean pixel value * total number of pixels The source tab in layer properties has all the information you need for this calculation.


Similar to another answer, move the raster data into NumPy masked arrays to calculated your statistics. Assuming two overlaying rasters with same shape, this is simple: import numpy as np zones = arcpy.RasterToNumPyArray("zones") value = np.ma.masked_equal(arcpy.RasterToNumPyArray("value"), arcpy.Raster("value").noDataValue) ...


There is a bug that seems to correspond to what you're experiencing - it's registered as BUG-000084883 - The 'Ignore NoData in calculations' option in Zonal Statistics as Table tool {and Zonal Statistics tool} is not honored when checked off, producing incorrect results. It occurs with 10.3 and 10.2.2 but not 10.1. Did you try the tool with this version?


It is a bug. Something terribly wrong with cell count. Correct mean (9.0452380952381) times correct number of non-empty cells (420) divided by 297 (that is a cell count reported by tool) results in 12.7912457912458. That is a wrong average reported by tool. Results of my own toy size grids test:


I've tried to use affine transformation to match shapes and used, area of symmetric difference between target and match shapes (D) to calculate P = 1 - D/AreaOfShapeToMatch: Result looks like this: To find transformation coefficients using least squares technique shouldn't be a challenge if you know how to match points. You cannot use this ...

Top 50 recent answers are included