MercatorLatitudeScale

class MercatorLatitudeScale(thresh=85.0)[source]

Bases: proplot.axistools._ScaleBase, matplotlib.scale.ScaleBase

Axis scale that transforms coordinates as with latitude in the Mercator projection. Adapted from this matplotlib example. “The scale function is as follows:

\[\begin{split}y = \\ln(\\tan(\\pi x/180) + \\sec(\\pi x/180))\end{split}\]

The inverse scale function is as follows:

\[\begin{split}x = 180\\arctan(\\sinh(y))/\\pi\end{split}\]
Parameters

thresh (float, optional) – Threshold between 0 and 90, used to constrain axis limits between -thresh and +thresh.

Attributes Summary

name

The registered scale name.

Methods Summary

limit_range_for_scale(vmin, vmax, minpos)

Return vmin and vmax limited to some range within +/-90 degrees (exclusive).