Skip to main content

My personal plotnine theme package.

Project description

p9customtheme

My personal plotnine theme package. You can use it but changes to the theme will appear with minimal versioning.

If you want a reproducible experience make sure to pin the version in your dependency.

Plotnine is awesome and a big thanks to the developers for making it.

Installation

Install this theme using pip ur uv:

uv pip install p9customtheme

Usage

You can simply install the package. Once you import it the theme is set as the default:

import p9customtheme

That is all you need.

Here is a more complete example showing also the color scale option:

from p9customtheme import custom_discrete, custom_theme
import plotnine as p9
from plotnine.data import penguins

(
    p9.ggplot(penguins, p9.aes("species", "bill_length_mm", fill="island"))
    + p9.geom_boxplot()
    + custom_discrete()
    + p9.labs(
        title="Penguin bill length by species and island".title(),
        subtitle="A comparison based on example data",
        x="species",
        y="bill length [mm]",
        fill="Island",
    )
)

A boxplot with the custom theme

Development

To contribute to this tool, first checkout the code. Then create a new virtual environment:

cd p9customtheme
uv venv
source ./venv/bin/activate

Now install the dependencies and test dependencies:

uv pip install -e '.[test]'

Before any PR ensure the tests as passing with:

pytest .

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

p9customtheme-0.1.1.tar.gz (11.5 kB view details)

Uploaded Source

Built Distribution

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

p9customtheme-0.1.1-py3-none-any.whl (11.0 kB view details)

Uploaded Python 3

File details

Details for the file p9customtheme-0.1.1.tar.gz.

File metadata

  • Download URL: p9customtheme-0.1.1.tar.gz
  • Upload date:
  • Size: 11.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for p9customtheme-0.1.1.tar.gz
Algorithm Hash digest
SHA256 3505e539bfa317e4a34fbc1cc7d0db76345dbc436fe36455c1dce45867555135
MD5 61d13eb219078a7eeae8bced443c1bb9
BLAKE2b-256 673a4051605d521af21d542bd9438f3c0f565a4ab91638bdf35093061f506dc6

See more details on using hashes here.

Provenance

The following attestation bundles were made for p9customtheme-0.1.1.tar.gz:

Publisher: publish.yml on openpaul/p9customtheme

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

File details

Details for the file p9customtheme-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: p9customtheme-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 11.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for p9customtheme-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 0aed9abbc4d53a58a89ae9cab94c6168cc4889684c3c5bc2a1811b135e9acbbf
MD5 a2fda7e41a6812fd90681644f904a98f
BLAKE2b-256 20b2973daf23fe27c4927d4f71199047e2406c0434ec4eba4d692a1921835d13

See more details on using hashes here.

Provenance

The following attestation bundles were made for p9customtheme-0.1.1-py3-none-any.whl:

Publisher: publish.yml on openpaul/p9customtheme

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