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

Function _decade_less

lib/matplotlib/ticker.py:2367–2378  ·  view source on GitHub ↗

Return the largest integer power of *base* that's less than *x*. If *x* is negative, the exponent will be *greater*.

(x, base)

Source from the content-addressed store, hash-verified

2365
2366
2367def _decade_less(x, base):
2368 """
2369 Return the largest integer power of *base* that's less than *x*.
2370
2371 If *x* is negative, the exponent will be *greater*.
2372 """
2373 if x < 0:
2374 return -_decade_greater(-x, base)
2375 less = _decade_less_equal(x, base)
2376 if less == x:
2377 less /= base
2378 return less
2379
2380
2381def _decade_greater(x, base):

Callers 3

_decade_greaterFunction · 0.85
nonsingularMethod · 0.85
view_limitsMethod · 0.85

Calls 2

_decade_greaterFunction · 0.85
_decade_less_equalFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…