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

Method _get_col_row

lib/mpl_toolkits/axes_grid1/axes_grid.py:184–190  ·  view source on GitHub ↗
(self, n)

Source from the content-addressed store, hash-verified

182 self._divider.new_locator(nx=2 * col, ny=2 * (self._nrows - 1 - row)))
183
184 def _get_col_row(self, n):
185 if self._direction == "column":
186 col, row = divmod(n, self._nrows)
187 else:
188 row, col = divmod(n, self._ncols)
189
190 return col, row
191
192 n_axes = property(lambda self: len(self.axes_all))
193 ngrids = _api.deprecated('3.11')(property(lambda self: len(self.axes_all)))

Callers 4

__init__Method · 0.95
_init_locatorsMethod · 0.95
__init__Method · 0.80
_init_locatorsMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected