diff --git a/raster_tools/zonal.py b/raster_tools/zonal.py index 1e8f9fe..15b1474 100644 --- a/raster_tools/zonal.py +++ b/raster_tools/zonal.py @@ -133,7 +133,18 @@ def _asm_entropy_fin(s, func): _DASK_STAT_NAMES = frozenset( - ("max", "mean", "median", "min", "prod", "size", "std", "sum", "var") + ( + "count", + "max", + "mean", + "median", + "min", + "prod", + "size", + "std", + "sum", + "var", + ) ) _CUSTOM_STAT_NAMES = frozenset(("asm", "entropy", "mode", "nunique")) _CUSTOM_STAT_AGGS = { diff --git a/tests/test_zonal.py b/tests/test_zonal.py index 3231d52..7fd63a0 100644 --- a/tests/test_zonal.py +++ b/tests/test_zonal.py @@ -113,7 +113,7 @@ def rasters_to_zonal_df(feat_raster, data_raster): "stats", [ ["max", "mean", "median", "min", "size", "std", "sum", "var"], - ["asm", "entropy", "mode", "nunique", "mean", "var"], + ["asm", "entropy", "mode", "nunique", "mean", "var", "count"], ["asm", "median"], "median", ["mean", "median"],