diff --git a/mlair/plotting/postprocessing_plotting.py b/mlair/plotting/postprocessing_plotting.py index 7fe6bc2fe82f50cb011f325707f102d51549c174..1cb6181ac5d1428012ce17a59b60da708085fe44 100644 --- a/mlair/plotting/postprocessing_plotting.py +++ b/mlair/plotting/postprocessing_plotting.py @@ -734,7 +734,8 @@ class PlotCompetitiveSkillScore(AbstractPlotClass): data = data.to_dataframe("data").unstack(level=1).swaplevel() data.columns = data.columns.levels[1] self._labels = [str(i) + "d" for i in data.index.levels[1].values] - return data.stack(level=0).reset_index(level=2, drop=True).reset_index(name="data") + data = data.stack(level=0).reset_index(level=2, drop=True).reset_index(name="data") + return data.astype({"comparison": str, "ahead": int, "data": float}) def _plot(self, single_model_comparison=False): """Plot skill scores of the comparisons."""