Description
In glue_plotly/html_exporters I have written a simple plot.ly exporter for 2D scatter plots as an example - this exporter can be used by clicking on the 'save' icon in scatter viewers and selecting 'Save Plotly HTML page':
The code to do this is relatively simple - it relies on the viewer state (which represents the overall viewer options) and the list of layer state (viewer.state.layers
) to construct a plotly figure, which is then exported to HTML.
This should now be extended to other viewer types in glue, including the histogram, profile, and (if possible) image viewers. The table in this section of the docs:
http://docs.glueviz.org/en/latest/python_guide/data_viewer_options.html#viewer-options
provides a list of the viewer classes and associated viewer state and layer state classes.