Skip to content

Planning for pytplot 2.0 #159

@ericthewizard

Description

@ericthewizard

I'm creating this issue to start the discussion of moving to pytplot 2.0!

TLDR:

For those of you unaware, I've been developing a version of pytplot that uses matplotlib to generate the figures instead of pyqtgraph; the development has been occuring under the 'matplotlib-backend' branch:

https://github.com/MAVENSDC/PyTplot/tree/matplotlib-backend

There's a jupyter notebook with examples of using this backend at:

https://github.com/MAVENSDC/PyTplot/blob/matplotlib-backend/docs/PyTplot%20examples%20with%20matplotlib.ipynb

For pytplot 2.0, I suggest that we make this backend the default, and deprecate the current Qt backend. I also think we should make this release ASAP.


Why?

I'm sure most of you have encountered some of the recent problems with pyqtgraph; this update will fix all of those issues and introduce several new features.

Bugs this fixes:

New features:

  • Publication quality figures (in addition to 'save_png', this update adds the options: 'save_eps', for saving postscript files, 'save_svg', for saving SVG files, and 'save_pdf' for saving PDF files)
  • Ability to create figures in Jupyter notebooks, including in Google colab, Deepnote, etc.
  • Option to return the figure and axes objects, so users can directly manipulate their figures; this allows users to add text, images, or make any other changes matplotlib allows (closes Allow text labels inside the plot? #8)
  • Option to add error bars to line plots, set via the 'dy' option when creating the variable with store_data (closes Add error bars to tplot #60)
  • Automatic interpolation options for spectrograms with the 'x_interp', 'y_interp' options (closes Interpolation options for spectrograms #146)
  • Overplotting lines on top of spectrograms (closes Overplotting curves on a spectrum #150)
  • 'xsize', 'ysize' keywords, for specifying figure size in inches
  • 'xmargin', 'ymargin' options, for specifying the margin sizes
  • MMS-style data segment bars
  • Automatic figure generation in docs via Sphinx extensions (https://matplotlib.org/sampledoc/extensions.html)

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions