Skip to main content

hedron-charts

PyPI Python CI License: MIT

Visualization adapters and chart components for Hedron.

Beginner LineChart / BarChart / AreaChart / ScatterChart, Matplotlib static SVG/PNG, Plotly interactive JSON, and Altair/Vega-Lite specifications.

Package maturity: Beta · Package version: 0.2.0

Interactive Plotly/Vega full browser runtimes remain experimental: Hedron ships host shims that fail closed when window.Plotly / window.vegaEmbed are missing. Applications may supply pinned local runtimes; first-party offline runtime pins exist for Experimental interactive hosts and are not Supported production Auto defaults.

Phase 0.38 first-party charts

Phase 0.38 ships hedron-charts 0.2.0 with typed ChartSpec / ChartPlan and an ABI-conforming hedron-chart Web Component (SVG default, Canvas for dense marks), publication-quality layout, accessible keyboard interactions, deterministic export, visual regression review, and hard performance/security budgets. Matplotlib remains Supported; Plotly/Altair stay Experimental. See RFC-0069 and the phase 0.38 acceptance packet.

Install

pip install "hedron[charts]>=0.38.0,<0.39"
# independent satellite:
pip install "hedron-charts>=0.2.0,<0.3"
# Add a backend when needed:
pip install "hedron-charts[matplotlib]>=0.2.0,<0.3"

Pin the living charts line at >=0.2.0,<0.3 for the Published 0.38 train.

Optional backends

Extra Backend
matplotlib Matplotlib static SVG/PNG
plotly Plotly figure JSON
altair Altair / Vega-Lite (+ vl-convert)
pydeck / folium Map layers
graphviz / networkx Graph layouts
bokeh / holoviews / pygal / datashader / great_tables Additional adapters
all Union of the above

Backend extras are optional and should be installed only for the adapter in use.

Quick start

from hedron_charts import LineChart

chart = LineChart(
    [{"month": "Jan", "revenue": 10}, {"month": "Feb", "revenue": 14}],
    x="month",
    y="revenue",
    title="Monthly revenue",
    description="Revenue increased during the period.",
)

LineChart falls back to SVG without Matplotlib. For an explicit Matplotlib figure:

import matplotlib.pyplot as plt
from hedron_charts import MatplotlibChart

fig, ax = plt.subplots()
ax.plot([1, 2, 3], [1, 4, 9])
chart = MatplotlibChart(fig, alt="y = x squared", description="Quadratic growth")

Links

License

MIT. See the repository license.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hedron_charts-0.2.0.tar.gz (2.9 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

hedron_charts-0.2.0-py3-none-any.whl (2.9 MB view details)

Uploaded Python 3

File details

Details for the file hedron_charts-0.2.0.tar.gz.

File metadata

  • Download URL: hedron_charts-0.2.0.tar.gz
  • Upload date:
  • Size: 2.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.12.1 {"installer":{"name":"uv","version":"0.12.1","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for hedron_charts-0.2.0.tar.gz
Algorithm Hash digest
SHA256 5d4d46667d7e470bcc77f73b5faa878c57bab5d90167d68ca11a32b7147a054e
MD5 92441ad075bec813cd70f974e9ce9ce2
BLAKE2b-256 1dfee01499d1e3302baf7bef78997552212087011bc5cb9ce5760888c4a8e072

See more details on using hashes here.

File details

Details for the file hedron_charts-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: hedron_charts-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 2.9 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.12.1 {"installer":{"name":"uv","version":"0.12.1","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for hedron_charts-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 a083f84e2f537ffba6ccd0e18d12475a776c9e7a4b9c5404fefba20f7912f26b
MD5 6a5b1638f31726cd6078a35f894768c3
BLAKE2b-256 d783c9b4284398d104fb13946e52401b026e8819ca1f3dcda95a295004bc9c7c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page