MCPcopy Index your code
hub / github.com/matplotlib/matplotlib / nonsingular

Method nonsingular

lib/matplotlib/ticker.py:1782–1796  ·  view source on GitHub ↗

Adjust a range as needed to avoid singularities. This method gets called during autoscaling, with ``(v0, v1)`` set to the data limits on the Axes if the Axes contains any data, or ``(-inf, +inf)`` if not. - If ``v0 == v1`` (possibly up to some floating poin

(self, v0, v1)

Source from the content-addressed store, hash-verified

1780 return locs
1781
1782 def nonsingular(self, v0, v1):
1783 """
1784 Adjust a range as needed to avoid singularities.
1785
1786 This method gets called during autoscaling, with ``(v0, v1)`` set to
1787 the data limits on the Axes if the Axes contains any data, or
1788 ``(-inf, +inf)`` if not.
1789
1790 - If ``v0 == v1`` (possibly up to some floating point slop), this
1791 method returns an expanded interval around this value.
1792 - If ``(v0, v1) == (-inf, +inf)``, this method returns appropriate
1793 default view limits.
1794 - Otherwise, ``(v0, v1)`` is returned without modification.
1795 """
1796 return mtransforms._nonsingular(v0, v1, expander=.05)
1797
1798 def view_limits(self, vmin, vmax):
1799 """

Callers 3

_autoscale_axisMethod · 0.45
_set_axes_scaleMethod · 0.45
_set_limMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected