Plotly
Published in

Plotly

🌻 Plotly.py End of Summer Updates 🌻

Static Image Export and a New Lead Maintainer

Quickstart

plotly.io.write_image(fig, file, format=None,
scale=None, width=None, height=None)
  • fig is a Figure or a compatible dict. This is the central declarative object that describes every aspect of a plotly graph.
  • file may be a string referring to a local filesystem path, or a file-like object to be written to. If file is a string, then the file extension is used to infer the image format if possible.
  • The format may be used to explicitly specify the format, and it is required if file is not a string with a common extension. Supported formats are png, jpeg (jpg extension supported as well), webp, svg, pdf, and eps (with poppler installed).
  • scale, width, and height all work as you would expect.
plotly.io.to_image(fig, format=None,
scale=None, width=None, height=None)
  1. $ pip install plotly --upgrade
  2. $ conda install -c plotly plotly
  1. $ conda install -c plotly plotly-orca
  2. $ npm install -g electron@1.8.4 orca
  3. Download and install the prebuilt binary

Performance

plotly.py image export is fast 🏇
The benchmark image.

Architecture

High-quality image export with plotly.py and orca

More Resources

--

--

Plotly is a data visualization company that makes it easy to build, test, and deploy beautiful interactive web apps, charts and graphs—in any programming language.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Plotly

The low-code framework for rapidly building interactive, scalable data apps in Python.