From 041f4d0c2cb5566496207dd223d0a4e8f41c3641 Mon Sep 17 00:00:00 2001 From: Lukas Prause Date: Thu, 6 Jul 2023 12:47:02 +0200 Subject: [PATCH] Adds plot styling. --- plot_stacked_bandwidth.py | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/plot_stacked_bandwidth.py b/plot_stacked_bandwidth.py index f3bb376..260050e 100755 --- a/plot_stacked_bandwidth.py +++ b/plot_stacked_bandwidth.py @@ -9,8 +9,8 @@ import matplotlib.pyplot as plt plt_params = { "pgf.texsystem": "lualatex", - "legend.fontsize": "x-large", - "figure.figsize": (15, 5), + #"legend.fontsize": "x-large", + #"figure.figsize": (15, 5), "axes.labelsize": 15, # "small", "axes.titlesize": "x-large", "xtick.labelsize": 15, # "small", @@ -20,7 +20,12 @@ plt_params = { "mathtext.fontset": "dejavusans", } -plt.rcParams.update(plt_params) +#plt.rcParams.update(plt_params) + +import seaborn as sns +sns.set() + +plt.rcParams["figure.figsize"] = (10, 3) if __name__ == "__main__": parser = ArgumentParser() @@ -71,7 +76,8 @@ if __name__ == "__main__": ax = df[bw_cols].plot.area(stacked=True, linewidth=0) ax.set_ylabel("bandwidth [MHz]") ax.set_xlabel("time [minutes]") - ax.set_xlim([0,df.index[-1]]) + ax.set_xlim([0, df.index[-1]]) + ax.xaxis.grid(False) L = plt.legend()