Add matplotlib style file for plots - #36
Conversation
| ytick.labelsize: x-small # font size of the tick labels | ||
| legend.fontsize: 10 | ||
| figure.titlesize: large # size of the figure title (``Figure.suptitle()``) | ||
| figure.labelsize: large # size of the figure label (``Figure.sup[x|y]label()``) |
There was a problem hiding this comment.
I think I'm using an older version of matplotlib (v3.5.1) or something. Mine complains that
Bad key figure.labelsize in file project.mplstyle, line 23 ('figure.labelsize: large # size of the figure label (``Figure.sup[x|y]label()``)')
But it works if I comment this out
There was a problem hiding this comment.
Thanks for checking! Yes, it seems like I have v3.10.x and higher. I can poke at this to see if there might be backward compatible options for the label sizes.
| font.family: cm # Make the default font consistent | ||
|
|
||
| # Set a default group for line colors and dash styles | ||
| axes.prop_cycle: cycler('color', [ "#EE2E2F", "#185AA9", "#008C48", "#F47D23", "#662C91", "#A21D21", "#B43894", "#010202"]) + cycler('linestyle', [ [], [10, 5], [10, 4, 3, 4], [3, 3], [10, 4, 3, 4, 3, 4], [3, 2,6,2], [3,4,1,4], [1,1] ]) |
There was a problem hiding this comment.
I got a complaint from matplotlib that
Bad value in file 'project.mplstyle', line 31 ('axes.prop_cycle: cycler('color', [ "#EE2E2F", "185AA9", "008C48", "F47D23", "662C91", "A21D21", "B43894", "010202"]) + cycler('linestyle', [ [], [10, 5], [10, 4, 3, 4], [3, 3], [10, 4, 3, 4, 3, 4], [3, 2,6,2], [3,4,1,4], [1,1] ])'): Key axes.prop_cycle: 'cycler('color', [ "' is not a valid cycler construction: EOL while scanning string literal (, line 1)
I think this got fixed in later versions, but it is interpreting the # in #EE2E2F as a comment, so it's not reading the rest of the line. However, by removing the # marks, my version of matplotlib still knows to read those as colors.


Start of PR to demonstrate adding a consistent style to plots