# Calculating value sum of cells inside drawn polygon using ArcMap?

How to calculate the value sum of cells inside a drawn polygon?

I need to measure the caloric output of countries and caloric output of Oil Fields polygons separately. My setup: SHP file World Borders, SHP file OilFields and TIF file Post1500OptCalories, I’m working in geographic projection WGS 84. I’m using the zonal statistics as table tool, and interested in the statistics type “SUM”. There are no problems calculating caloric output for countries, but calculating caloric output for Oil Fields polygons brings very suspicious results.

On the Picture 1 you can see that values in the column “SUM” are less than values in columns “MAX” and “MEAN”. Somewhere column “MAX” have zeros while corresponding values in the “MIN” column are strictly higher than zeros. When I try to calculate different statistics separately, e.g. “SUM” or “MEAN”, I get the same values for these statistics as in the “MIN” column when I’m calculating all statistics simultaneously (unfortunately, I'm not allowed to add more pictures). Conclusion: computed caloric output of OilFields polygons is incorrect.

I’m sorry for my English and poor knowledge of ArcGIS software.

Does anyone know what can be the problem?

• Truly weird results. What field in oil polygons are you using? I cannot see one in output summary table. Sep 22 '17 at 17:32
• @FelixIP Thank you for the support. It looks like this could be the problem. There are two zone fields in oil polygons shp: FID an Id. When I use FID, I get those weird results. If I use Id instead, I get the one row table with computed statistics. It looks like ArcGIS considers all polygons as one common thing (when using Id), and calculates aggregated statistics, since obtained values are pretty convincing. I have edited the post and add a picture with zone fields. Sep 22 '17 at 20:14
• Your I'd must be unique. Populate it using field calculator, eg [fid]+1. Sep 22 '17 at 20:36
• @FelixIP I followed your recommendation and now everything is fine. Thank you very much for your help! Sep 23 '17 at 13:55