By Jay Cummins


2016-09-20 18:06:41 8 Comments

I'm getting different results when using the ZonalStatisticsAsTable tool in 10.4.1 when compared to earlier versions (10.2 and 10.3).

ArcGIS 10.2:
enter image description here

ArcGIS 10.3:
enter image description here

But in ArcGIS 10.4.1, the same data produces this table as a result:
enter image description here

For each test, I used the same statistic type and checked the option to ignore NODATA in the calculation.

enter image description here

Has the earlier versions been incorrect, and 10.4.1 is correct? Or is 10.4.1 incorrect?

I have a set of reproducible test data here:
https://bitbucket.org/CumminsJP/zonalstatisticsastable-issue-104/src

2 comments

@Ben Gosack 2016-10-27 20:12:10

I was experiencing the same issue as you. I wrote a python script using arcpy on version 10.2.2, which worked fine. But, when I upgraded to 10.4.1, I was getting MEAN values returned from arcpy.sa.ZonalStatisticsAsTable() that were way out of the value range of the input value raster.

For me, the fix was to stop using "OBJECTID" as the zone field. Looks like you are also calling "FID" as your zone field.

Try using a different field than OID, FID, or OBJECTID to delineate your zones.

@Jay Cummins 2016-09-26 17:36:43

I opened a support incident w/Esri and confirmed this to be an existing bug for 10.4:
BUG-000096325 - The 'Zonal Statistics as Table' tool from the Spatial Analyst toolbox shows different values in ArcMap 10.4 as compared to ArcMap 10.3.1.

Since I was calling zonal statistics from a python script, my current workaround is to use rasterstats instead which works well, unless you are executing in an ArcSOC.exe process( see How to resolve "'NoneType' object is not callable" TypeError when calling rasterstats.zonal_stats from ArcPy script?).

Related Questions

Sponsored Content

0 Answered Questions

1 Answered Questions

[SOLVED] Errors with Append tool 000594

0 Answered Questions

0 Answered Questions

Why are Moran's Index calculated in GeoDa and ArcGIS different?

3 Answered Questions

[SOLVED] Major bug in ArcGIS Zonal statistics?

1 Answered Questions

1 Answered Questions

[SOLVED] Getting error in running ExportReport Python code in ArcMap

Sponsored Content