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.9.5.tar.gz (875.9 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.9.5-py3-none-any.whl (44.9 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for plastik-0.9.5.tar.gz
Algorithm Hash digest
SHA256 1b3075e5891a7edffbd4d25f5f36439245825db6282bccde2452f798a84e3b7e
MD5 b4eee77da5b812a72c6c13d8c3198f49
BLAKE2b-256 4bb006a14e185642ed76c3cf2a957ce999da3322ed56efd7ef60cbbbdd8cc4aa

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for plastik-0.9.5-py3-none-any.whl
Algorithm Hash digest
SHA256 0ecfcaddea3952199ad2b0fcc56c624a346015e502adc346aaebfb3e0ae4c1c2
MD5 56a208e4a6d479c4260e765b80a1288a
BLAKE2b-256 fb81a9f9c08d8232c4d3c108d3e2b6b26aaff204bfe9e6516bdf0b32f7f9d6c3

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