mpl_interactions.zoom_factory

zoom_factory(ax, base_scale=1.1)[source]

Add ability to zoom with the scroll wheel.

Parameters
  • ax (matplotlib axes object) – axis on which to implement scroll to zoom

  • base_scale (float) – how much zoom on each tick of scroll wheel

Returns

disconnect_zoom (function) – call this to disconnect the scroll listener