Skip to main content

plastic surgery for plt

Project description

plastik

pre-commit Code style: black

plt assist, plastic surgery for plt

Install

plastik is available through PyPI:

pip install plastik

Installing the development version is done using uv:

git clone https://github.com/engeir/plastik.git
cd plastik
uv sync

Usage

import matplotlib as mpl
import matplotlib.pyplot as plt
import numpy as np

import plastik

mpl.style.use("plastik.default")
fig, axs = plastik.figure_grid(
    2,
    2,
    {
        "labels": ["Hello subplot title", 1, r"$4\hbar$", None],
        "pos": (0.6, 0.1),
        "share_axes": "x",
        "columns_first": True,
    },
)
for i, ax in enumerate(axs):
    ax.plot(np.array([1, 2, 3]), np.array([1, 2, 3]) * i)
fig.savefig("figure_grid_opts.png")
plt.show()

See more examples and their output.

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

plastik-0.10.3.tar.gz (876.6 kB view details)

Uploaded Source

Built Distribution

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

plastik-0.10.3-py3-none-any.whl (45.1 kB view details)

Uploaded Python 3

File details

Details for the file plastik-0.10.3.tar.gz.

File metadata

  • Download URL: plastik-0.10.3.tar.gz
  • Upload date:
  • Size: 876.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.21

File hashes

Hashes for plastik-0.10.3.tar.gz
Algorithm Hash digest
SHA256 16dfbd8b6c76fd1044587d7e9c2dd85078858ca0d29f6d4eb3fce622379e6a7a
MD5 c8e3d726246f24237f49b897a405cfae
BLAKE2b-256 d9924eb6c657e739bdd0fddc84cce443f59fb7ab1340830ddf908b7679cf449b

See more details on using hashes here.

File details

Details for the file plastik-0.10.3-py3-none-any.whl.

File metadata

  • Download URL: plastik-0.10.3-py3-none-any.whl
  • Upload date:
  • Size: 45.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.21

File hashes

Hashes for plastik-0.10.3-py3-none-any.whl
Algorithm Hash digest
SHA256 433d2a733afeace3fafc49aabfb473bc4c03e9d77ea3cc81cae8c845f8b99c0f
MD5 29a4b7467d769a0b720242156071fe09
BLAKE2b-256 550977514131c496fbb17493c85e6be1a68e04df8bd432f7529e939ffcf4a516

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 Pingdom Monitoring Sentry Error logging StatusPage Status page