From 7a175e7f0a8c9b521b55ed7864d631d479490f94 Mon Sep 17 00:00:00 2001 From: Samuel ORTION Date: Wed, 24 Aug 2022 12:00:47 +0200 Subject: [PATCH] plot: Fix date in chart title --- daemon/plotter/chart.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/daemon/plotter/chart.py b/daemon/plotter/chart.py index ca2b930..e06aab2 100755 --- a/daemon/plotter/chart.py +++ b/daemon/plotter/chart.py @@ -100,9 +100,9 @@ def chart(date): plot.set(ylabel=None) plot.set(xlabel="Hour of day") - plt.suptitle(f"Top {CONFIG['readings']} species on {CONFIG['date']}", fontsize=14) + plt.suptitle(f"Top {CONFIG['readings']} species on {date}", fontsize=14) plt.text(15, 11, f"(Updated on {datetime.now().strftime('%Y/%m-%d %H:%M')})") - plt.savefig(f"./var/charts/chart_{CONFIG['date']}.png", dpi=300) + plt.savefig(f"./var/charts/chart_{date}.png", dpi=300) print(f"Plot for {date} saved.") plt.close()