Skip to main content

Bringing interactivity to plotnine

Project description

ninejs

Bring interactivity to plotnine charts.

ninejs lets you add tooltips and hover grouping to plotnine plots directly from aes(...), then export the result as standalone HTML.


Quick start

from plotnine import aes, geom_point, ggplot, theme_minimal
from plotnine.data import anscombe_quartet

from ninejs import css, interactive, save

gg = (
  ggplot(
      anscombe_quartet,
      aes(x="x", y="y", color="dataset", tooltip="dataset", data_id="dataset")
  )
  + geom_point(size=7, alpha=0.5)
  + theme_minimal()
)

(
  interactive(gg)
  + css(from_dict={".tooltip": {"font-size": "2em"}})
  + save("plot.html")
)


Installation

pip install ninejs

Documentation

See the full documentation and examples here.

Project details


Download files

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

Source Distribution

ninejs-0.0.2.tar.gz (97.8 kB view details)

Uploaded Source

Built Distribution

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

ninejs-0.0.2-py3-none-any.whl (11.8 kB view details)

Uploaded Python 3

File details

Details for the file ninejs-0.0.2.tar.gz.

File metadata

  • Download URL: ninejs-0.0.2.tar.gz
  • Upload date:
  • Size: 97.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for ninejs-0.0.2.tar.gz
Algorithm Hash digest
SHA256 0dc46b71fe9ce15f8cbf147d15f89615e81d011e2d25af72d896611871c09f12
MD5 c5f5a720bc163f217aedce4943555598
BLAKE2b-256 31dbe4eba26a672c71a84497920861c0d32253dff3cbb1baf1ea0d41f6480112

See more details on using hashes here.

Provenance

The following attestation bundles were made for ninejs-0.0.2.tar.gz:

Publisher: pypi.yaml on y-sunflower/ninejs

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ninejs-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: ninejs-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 11.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for ninejs-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 2cef84bcb6b090abba1f1a5df8ba7ce5fe3bac97a86fe8cdc0c409c3b202002e
MD5 ac136eb4d5ef7a563618dea1e9935b2e
BLAKE2b-256 a7583882dc7353f2f8ff8eb061175be78ac6517cb4dc36e25fe5d2dc37d0480b

See more details on using hashes here.

Provenance

The following attestation bundles were made for ninejs-0.0.2-py3-none-any.whl:

Publisher: pypi.yaml on y-sunflower/ninejs

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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