Update: version 5.0 was released since this was posted.
I’m happy to announce that Plotly.py 4.14 is now available for download via
conda! For up-to-date installation and upgrading instructions (including the extra required steps for JupyterLab!) please see our Getting Started documentation page and if you run into trouble, check out our Troubleshooting Guide.
Our changelog has details and links to individual pull requests, but here are the highlights:
px.imshow() function has always allowed you to visualize single-chanel 2-dimensional data as a heatmap, and 3-channel (RGB) 2-dimensional data as an image. As of this release,
px.imshow() supports 3- and 4-dimensional single and multi-channel data, via faceting and/or animation. This means that if you have a list or array of images, you can see them all at once side by side using
facet_col or you can step through them with a slider using
animation_frame, and if you have a list of lists of images, you can use both together! Of course, in addition to working with lists of lists and
numpy arrays, this also works well with the
xarray library, which is a common way of storing and processing these higher-dimensional arrays.
This feature, like the rest of the
px.imshow() function, was sponsored as part of a Chan-Zuckerberg Initiative Essential Open-Source Software for Science grant
Here are some examples of what this looks like:
For a cleaner look, you can now move the tick labels of your cartesian axes inside the plotting area, and the automatic ranging will leave enough room for the data to not overlap with the tick labels.
This feature was anonymously sponsored.
One issue which has bothered users of Plotly.py for years is that the axis type-detection system in Plotly.js by default treats numeric strings as numbers, which has caused it to automatically consider lists of strings containing a mix of numeric and non-numeric strings as mapping to
linear axes and thereby ignoring the non-numeric strings. In Plotly.py 4.14, numeric strings are now treated just like strings that don’t contain numbers for the purposes of axis
type detection, which should result in less surprise and confusion, and less need for forcing the axis type to
category when passing in lists of strings!
The version of Plotly.js that Plotly.py 4.14 is built on is the same one that’s bundled with the recently-released Dash 1.18 so we recommend that if you’re a Dash user you upgrade to both Dash 1.18 and Plotly.py 4.14 to get the full benefit of all of these libraries working together.
To sum up: Plotly.py 4.14 is out and if you’re excited about any of the above features, head on over to our Getting Started documentation page for full installation instructions, and don’t forget to upgrade your JupyterLab extensions if that is your environment of choice!
- Magical error messages
- Performance improvements (including for Dash!)
- Faceted Maps
- Horizontal and vertical lines and rectangles
- Period positioning on
- Period positioning on
- Full Figures for Development
- A Faster
- Kaleido for static image export
- Hexbin Tile Maps
- Plotly Express Support for Wide- and Mixed-Form Data
- a Pandas backend
- Major performance improvments
- unified hover labels
- excluding weekends from time-series axes