Skip to content

Commit 7e8df85

Browse files
committed
fix(group id): fix categories problem
1 parent d4af1a7 commit 7e8df85

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

climada/trajectories/risk_trajectory.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -293,6 +293,7 @@ def _generic_metrics(
293293
~tmp.index.duplicated(keep="last")
294294
] # We want to avoid overlap when more than 2 snapshots
295295
tmp = tmp.reset_index()
296+
tmp["group"] = tmp["group"].cat.add_categories([self._all_groups_name])
296297
tmp["group"] = tmp["group"].fillna(self._all_groups_name)
297298
columns_to_front = ["group", "date", "measure", "metric"]
298299
tmp = tmp[

0 commit comments

Comments
 (0)