From 8adbbfd5fe4213533ac21b9648d306cab900ab7b Mon Sep 17 00:00:00 2001 From: leufen1 <l.leufen@fz-juelich.de> Date: Wed, 18 Nov 2020 13:48:27 +0100 Subject: [PATCH] error occurred if only a single subplot was created, now squeeze is disabled, bug is fixed --- mlair/plotting/postprocessing_plotting.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mlair/plotting/postprocessing_plotting.py b/mlair/plotting/postprocessing_plotting.py index caefbd82..f0b6baeb 100644 --- a/mlair/plotting/postprocessing_plotting.py +++ b/mlair/plotting/postprocessing_plotting.py @@ -838,8 +838,8 @@ class PlotTimeSeries: factor = 1 if self._sampling == "h": factor = 2 - f, ax = plt.subplots((end - start + 1) * factor, sharey=True, figsize=(50, 30)) - return f, ax, factor + f, ax = plt.subplots((end - start + 1) * factor, sharey=True, figsize=(50, 30), squeeze=False) + return f, ax[:, 0], factor def _plot_ahead(self, ax, data): color = sns.color_palette("Blues_d", self._window_lead_time).as_hex() -- GitLab