Skip to content

Commit

Permalink
Add plot_legend_loc parameter to settings (#698)
Browse files Browse the repository at this point in the history
Closes #685
  • Loading branch information
MichaelGrupp authored Oct 29, 2024
1 parent cc9ba39 commit a6a2e6c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
1 change: 1 addition & 0 deletions evo/tools/plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ def apply_settings(settings: SettingsContainer = SETTINGS):
palette=settings.plot_seaborn_palette)

mpl.rcParams.update({
"legend.loc": settings.plot_legend_loc,
"lines.linewidth": settings.plot_linewidth,
"text.usetex": settings.plot_usetex,
"font.family": settings.plot_fontfamily,
Expand Down
5 changes: 5 additions & 0 deletions evo/tools/settings_template.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,11 @@ def get_default_plot_backend() -> str:
False,
"Invert the y-axis of plots."
),
"plot_legend_loc": (
"best",
"Plot legend location. See here for the available 'loc' options:\n"
"https://matplotlib.org/stable/api/_as_gen/matplotlib.pyplot.legend.html"
),
"plot_linewidth": (
1.5,
"Line width value supported by matplotlib."
Expand Down

0 comments on commit a6a2e6c

Please sign in to comment.