Skip to main content

canvasxpress-magic

A %%cxplot IPython / Jupyter magic for CanvasXpress — render an interactive chart straight from a notebook cell, no HTML or JavaScript. Works in Jupyter, JupyterLab and VS Code notebooks; the chart is a self-contained iframe that loads CanvasXpress from the CDN, so there is nothing to build.

Install

pip install canvasxpress-magic

Use

%load_ext canvasxpress_magic

Cell magic — the cell body is a JSON {"data", "config"} spec:

%%cxplot
{"data": {"y": {"vars": ["Revenue"],
                "smps": ["Q1", "Q2", "Q3", "Q4"],
                "data": [[10, 14, 9, 17]]}},
 "config": {"graphType": "Bar", "title": "Quarterly Revenue"}}

Line magic — render a spec held in a Python variable:

spec = {"data": {...}, "config": {"graphType": "Line"}}
%cxplot spec

Both accept sizing flags:

%%cxplot --width 800 --height 500
{ ... }

data and config are exactly the arguments of new CanvasXpress({...}), so any spec from the gallery or the R / Python packages works unchanged.

License

This package is MIT-licensed. The CanvasXpress JavaScript library it loads is distributed separately under the CanvasXpress Community License (Attribution), free with a visible attribution mark and with commercial terms for mark removal — see https://www.canvasxpress.org/license.html. https://canvasxpress.org/license.html.

Metadata

Release files for canvasxpress-magic 0.1.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for canvasxpress-magic 0.1.1
File Size Uploaded
canvasxpress_magic-0.1.1.tar.gz 3.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for canvasxpress-magic 0.1.1
File Interpreter ABI Platform
canvasxpress_magic-0.1.1-py3-none-any.whl Python 3 none any Details

Total release size: 8.5 kB

Release files / canvasxpress_magic-0.1.1.tar.gz

Download URL canvasxpress_magic-0.1.1.tar.gz
Size 3.8 kB
Tags Source
SHA-256 checksum
How to use checksums
2a375bb578ca705ec509a93b6d1cba88e643ba7a68ab55cd182b5305fdfd8b83
BLAKE2b-256 checksum
How to use checksums
2ba9a06d553742106decd991b6fa7df2dbedf1a0b1e2284c32531d63e71e9d13
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 15, 2026.

Transparency log

Release files / canvasxpress_magic-0.1.1-py3-none-any.whl

Download URL canvasxpress_magic-0.1.1-py3-none-any.whl
Size 4.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e69ffbeda8c3488182d0fbd528d082e2577d3d088ec747daf9a21646e72c058f
BLAKE2b-256 checksum
How to use checksums
2794a164b2d1a4239c5cc72d2841ff868f6bddd28e3d008818c8770bebb98c42
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Sep 15, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.1 This release

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page