Skip to main content

Ternary plots as projections of Matplotlib

Project description

PyPI version PyPI Conda Version Conda Downloads

GitHubActions CircleCI

DOI

Mpltern (https://yuzie007.github.io/mpltern) is a Python plotting library based on Matplotlib specifically designed for ternary plots. Mpltern is implemented as a new projection for Matplotlib, with introducing e.g. new Transform classes for ternary plots. The followings are the features of mpltern when compared with other ternary-plot libraries:

  • Many things one expects essentially possible using Matplotlib can be done also in mpltern, without e.g. ternary-to-Cartesian conversions on the user side

  • For the same plotting styles, mpltern offers the same or very similar method names as Matplotlib does; you do not need to learn many new commands in addition to those for Matplotlib

  • Tick markers, tick labels, and axis labels are automatically positioned with reasonable paddings inherited from Matplotlib; this allows users e.g. faster production of ternary plots with publication quality

  • tight_layout and constrained_layout

  • Easy combination with normal Matplotlib plots

  • Easy application of seaborn styles

  • Working also in Matplotlib interactive modes inside e.g. Jupyter notebooks

https://mpltern.readthedocs.io/en/latest/_images/sphx_glr_with_seaborn_styles_001.svg https://mpltern.readthedocs.io/en/latest/_images/sphx_glr_05.inset_001.svg https://mpltern.readthedocs.io/en/latest/_images/sphx_glr_07.polygon_001.svg https://mpltern.readthedocs.io/en/latest/_images/sphx_glr_02.arbitrary_triangle_001.svg
https://mpltern.readthedocs.io/en/latest/_images/sphx_glr_01.scatter_001.svg https://mpltern.readthedocs.io/en/latest/_images/sphx_glr_08.quiver_001.svg
https://mpltern.readthedocs.io/en/latest/_images/sphx_glr_02.contour_001.svg https://mpltern.readthedocs.io/en/latest/_images/sphx_glr_03.pseudocolor_001.svg

Installation

See the install documentation.

Basic Usage

See the basic usage documentation.

See more examples in the gallery.

How to Cite mpltern

The author requests to cite mpltern via the DOI above if mpltern contributes to a scientific publication. Of course, Matplotlib should be also very much acknowledged when using mpltern.

Author

Yuji Ikeda (GitHub, Google Scholar, ResearchGate)

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

mpltern-0.4.0.tar.gz (911.6 kB view details)

Uploaded Source

Built Distribution

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

mpltern-0.4.0-py3-none-any.whl (20.8 kB view details)

Uploaded Python 3

File details

Details for the file mpltern-0.4.0.tar.gz.

File metadata

  • Download URL: mpltern-0.4.0.tar.gz
  • Upload date:
  • Size: 911.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.11.0

File hashes

Hashes for mpltern-0.4.0.tar.gz
Algorithm Hash digest
SHA256 d550a5ab0d4dade805c6c03720d86fb509847662e6d88aa4158584b9fec69e20
MD5 fdb61478bac274aa1308dfd362f68689
BLAKE2b-256 df83972f10f44ec581e31512270ffeed10410f01314059931a07bbcb4116e208

See more details on using hashes here.

File details

Details for the file mpltern-0.4.0-py3-none-any.whl.

File metadata

  • Download URL: mpltern-0.4.0-py3-none-any.whl
  • Upload date:
  • Size: 20.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.11.0

File hashes

Hashes for mpltern-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 cacd71b4083280c303a24473ce0f5578e6708f66bcd78afb96129339bab43f50
MD5 86a046cdaa649896911983c112666f79
BLAKE2b-256 3cf9629b0449c84e95a7f8854db5a8fb83bbf4b829add956def312113cc22fd8

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