Skip to content

Commit beec918

Browse files
committed
set numeric_only in geomap sum to avoid concatting strings
1 parent ea6e3d7 commit beec918

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

_delphi_utils_python/delphi_utils/geomap.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -401,7 +401,7 @@ def replace_geocode(
401401
df.drop("weight", axis=1, inplace=True)
402402

403403
if not date_col is None:
404-
df = df.groupby([date_col, new_col]).sum().reset_index()
404+
df = df.groupby([date_col, new_col]).sum(numeric_only=True).reset_index()
405405
else:
406406
df = df.groupby([new_col]).sum().reset_index()
407407
return df

0 commit comments

Comments
 (0)