Skip to main content

A histogram+colorbar for matplotlib

Project description

mpl-histcolorbar logo

mpl-histcolorbar

PyPI version Coverage Status Documentation Status

A drop-in replacement for matplotlib's colorbar that shows the frequency of each color in the mappable.

Getting started

mpl-histcolorbar is available as mpl_histcolorbar on PyPI:

pip install mpl_histcolorbar

Usage

import numpy as np
import matplotlib.pyplot as plt
from mpl_histcolorbar import histcolorbar

rng = np.random.default_rng(seed=42)
data = rng.standard_normal(size=(25, 100))
fig, ax = plt.subplots()
im = ax.imshow(data)
hcb = histcolorbar(fig, im, location="bottom")

Example

Documentation is available at mpl-histcolorbar.readthedocs.io.

License

Original code is licensed under the MIT license. This project directly derives from matplotlib, and any use of this project is subject to the matplotlib license agreement.

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

mpl-histcolorbar-0.1.0.tar.gz (10.2 kB view details)

Uploaded Source

Built Distribution

mpl_histcolorbar-0.1.0-py3-none-any.whl (9.3 kB view details)

Uploaded Python 3

File details

Details for the file mpl-histcolorbar-0.1.0.tar.gz.

File metadata

  • Download URL: mpl-histcolorbar-0.1.0.tar.gz
  • Upload date:
  • Size: 10.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.16

File hashes

Hashes for mpl-histcolorbar-0.1.0.tar.gz
Algorithm Hash digest
SHA256 2a055aecbc522c7efaa7d6865f0b3bf6f6bdff57b6220af653411dd31e6cd706
MD5 8a0b93627653ff227f4eecfaf99d8878
BLAKE2b-256 4361c6e672a9fddbf00f145bac971931d4d4d5d83cae4bce4549db5e344c62d2

See more details on using hashes here.

Provenance

File details

Details for the file mpl_histcolorbar-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for mpl_histcolorbar-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 73ba884247dda4db25a70326236282946b44b345402ef8e0e45bc39c08204acc
MD5 b8264c1eb1cf94bc4212b74270a21ea4
BLAKE2b-256 76a46cca65eef7d9a10558bb6a004cd072ec455ab96012cab6e8985e76dee5ba

See more details on using hashes here.

Provenance

Supported by

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