Examples#

This gallery contains examples of mpltern.

Introductory#

Line and curve

Line and curve

Scatter

Scatter

Contour

Contour

Pseudocolor

Pseudocolor

Normalization

Normalization

Span

Span

Text

Text

Polygon

Polygon

Quiver

Quiver

Grid

Grid

Axis labels

Axis labels

Triangular grid

Triangular grid

AxLine

AxLine

Legend

Legend

Intermediate#

With normal Matplotlib plots

With normal Matplotlib plots

Style sheets

Style sheets

Inset

Inset

Statistics#

HexBin

HexBin

TriBin

TriBin

Binned & scatter

Binned & scatter

Axis and Tick#

The examples below show how to control tick markers, tick labels, and axis labels.

Axis-label position

Axis-label position

Axis-label rotation

Axis-label rotation

Tick position

Tick position

Tick direction

Tick direction

Tick rotation

Tick rotation

Tick formatters

Tick formatters

Tick locators

Tick locators

Manual tick positions

Manual tick positions

Manual tick labels

Manual tick labels

Colored axes

Colored axes

Tick labels inside triangle

Tick labels inside triangle

Ternary Limits#

Triangular limits

Triangular limits

Hexagonal limits

Hexagonal limits

Plotting region fitting

Plotting region fitting

Transforms#

Mpltern is implemented as a new projection of Matplotlib by implementing several new Transform classes for ternary plots. This allows us to auto-position tick markers, tick labels, and axis labels with reasonable paddings consistent with Matplotlib.

The examples below show how to use such Transform classes in mpltern.

Cartesian coordinates

Cartesian coordinates

Ticks

Ticks

Plot fixed onto triangle

Plot fixed onto triangle

Arrows along axes

Arrows along axes

Triangle#

Aspect

Aspect

Triangle rotation

Triangle rotation

Arbitrary triangle

Arbitrary triangle

Miscellaneous#

Mpltern logo

Mpltern logo

Dirichlet distribution

Dirichlet distribution

Evolutionary game theory

Evolutionary game theory

USDA soil texture classes

USDA soil texture classes

Gallery generated by Sphinx-Gallery