Skip to content

Added --style command-line option to gwpy-plot

Duncan Macleod requested to merge github/fork/duncanmmacleod/cli-rcparams into master

This PR adds a --style option for gwpy-plot documented as

  --style FILE          path to custom matplotlib style sheet, see
                        http://matplotlib.org/users/style_sheets.html#style-
                        sheets for details of how to write one

The argument is a path to a matplotlib style sheet, as documented here. This will allow users to customise their plots ad nauseam without manually editing python code.

In line with this I have removed the custom rcParams settings in gwpy.cli.cliproduct. These can be reinstated (e.g. on LDVW) with the following style file

figure.dpi: 100
font.family: sans-serif
font.size: 16
font.weight: book
legend.loc: best
lines.linewidth: 1.5
text.usetex: True
agg.path.chunksize: 10000

Merge request reports