v1.50: Networks, lollipops and sharing
UltraPlot v1.50
Version v1.50 is a major milestone for UltraPlot. As we become more familiar with the codebase, we’ve opened the door to new features—balancing innovation with continuous backend improvements and bug fixes.
🌍 GeoAxes Sharing
|
You can now share axes between subplots using GeoAxes, as long as they use the same rectilinear projection. This enables cleaner, more consistent layouts when working with geographical data. |
|
🕸️ Network Graphs
|
UltraPlot now supports network visualizations out of the box. With smart defaults and simple customization options, creating beautiful network plots is easier than ever. |
|
Network plotting code
import networkx as nx, ultraplot as uplt
n = 100
g = nx.random_geometric_graph(n, radius=0.2)
c = uplt.colormaps.get_cmap("viko")
c = c(np.linspace(0, 1, n))
node = dict(
node_size=np.random.rand(n) * 100,
node_color=c,
)
fig, ax = uplt.subplots()
ax.graph(g, layout="kamada_kawai", node_kw=node)
fig.show()🍭 Lollipop Graphs
|
A sleek alternative to bar charts, lollipop graphs are now available directly through UltraPlot. They shine when visualizing datasets with many bars, reducing visual clutter while retaining clarity. |
|
Lollipop example code
import ultraplot as uplt, pandas as pd, numpy as np
data = np.random.rand(5, 5).cumsum(axis=0).cumsum(axis=1)[:, ::-1]
data = pd.DataFrame(
data,
columns=pd.Index(np.arange(1, 6), name="column"),
index=pd.Index(["a", "b", "c", "d", "e"], name="row idx"),
)
fig, ax = uplt.subplots(ncols=2, share=0)
ax[0].lollipop(
data,
stemcolor="green",
stemwidth=2,
marker="d",
edgecolor="k",
)
ax[1].lollipoph(data, linestyle="solid")What's Changed
- separate logger for ultraplot and matplotlib by @cvanelteren in #178
- Capture warning by @cvanelteren in #180
- tmp turning of test by @cvanelteren in #183
- Skip missing tests if added in PR by @cvanelteren in #175
- Revert "Skip missing tests if added in PR" by @beckermr in #184
- rm conftest from codecov by @cvanelteren in #187
- skip tests properly by @cvanelteren in #186
- Fix colorbar loc by @cvanelteren in #182
- Fix bar alpha by @cvanelteren in #192
- make import uplt to be consistent with rest of repo by @cvanelteren in #195
- Ensure that shared labels are consistently updated. by @cvanelteren in #177
- sensible defaults and unittest by @cvanelteren in #189
- Deprecation fix mpl 3.10 and beyond by @cvanelteren in #69
- Add network plotting to UltraPlot by @cvanelteren in #169
- Hotfix test by @cvanelteren in #196
- Discrete colors for quiver by @cvanelteren in #198
- correct url for basemap objects by @cvanelteren in #202
- override logx/y/log with updated docstring by @cvanelteren in #203
- Add lollipop graph by @cvanelteren in #194
- Fix network linking in docs and api refs by @cvanelteren in #205
- Avoid getting edges and setting centers for some shaders by @cvanelteren in #208
- Fix some references in inset docs by @cvanelteren in #209
- rm dep warning by @cvanelteren in #210
- [Feature add] Share Axes in GeoPlot + bug fixes by @cvanelteren in #159
Full Changelog: v1.11...v1.5


