From e933f16f2e4bb3d2e91a2e8a2ceea87c5320d0c2 Mon Sep 17 00:00:00 2001 From: Tomas Date: Tue, 7 Jul 2020 17:36:05 +0100 Subject: [PATCH] Update matplotlib style to ING theme --- popmon/visualization/utils.py | 4 +++- requirements-test.txt | 2 +- requirements.txt | 1 + 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/popmon/visualization/utils.py b/popmon/visualization/utils.py index 4fe36247..3a6411d7 100644 --- a/popmon/visualization/utils.py +++ b/popmon/visualization/utils.py @@ -26,10 +26,12 @@ import numpy as np import pandas as pd import pybase64 +from ing_theme_matplotlib import mpl_style NUM_NS_DAY = 24 * 3600 * int(1e9) logger = logging.getLogger() +mpl_style(dark=False) def plt_to_base64(): @@ -76,7 +78,7 @@ def plot_bars_b64(data, labels=None, bounds=None, ylim=False, skip_empty=True): index = np.arange(n) width = (index[1] - index[0]) * 0.9 if n >= 2 else 1.0 - ax.bar(index, data, width=width, align="center", alpha=0.5) + ax.bar(index, data, width=width, align="center") if labels: ax.set_xticks(index) diff --git a/requirements-test.txt b/requirements-test.txt index 27aa7832..ac78bb5d 100644 --- a/requirements-test.txt +++ b/requirements-test.txt @@ -5,4 +5,4 @@ nbconvert>=5.3.1 jupyter_client>=5.2.3 ipykernel>=5.1.3 black>=19.10b0 -isort>=4.3.21 +isort==4.3.21 diff --git a/requirements.txt b/requirements.txt index be57962b..a1b6812b 100644 --- a/requirements.txt +++ b/requirements.txt @@ -9,3 +9,4 @@ matplotlib>=2.2.3 joblib>=0.14.0 pybase64>=1.0.1 htmlmin +ing_theme_matplotlib