Matplotlib.axis.Axis.zoom() function in Python Last Updated : 08 Jun, 2020 Comments Improve Suggest changes Like Article Like Report Matplotlib is a library in Python and it is numerical – mathematical extension for NumPy library. It is an amazing visualization library in Python for 2D plots of arrays and used for working with the broader SciPy stack. Matplotlib.axis.Axis.zoom() Function The Axis.zoom() function in axis module of matplotlib library is used to zoom in or out on axis . Syntax: Axis.zoom(self, direction) Parameters: This method accepts the following parameters. direction: This parameter is the value to zoom in (direction > 0) or zoom out (direction <= 0). Return value: This method does not return any value. Below examples illustrate the matplotlib.axis.Axis.zoom() function in matplotlib.axis: Example 1: Python3 # Implementation of matplotlib function from matplotlib.axis import Axis import matplotlib.pyplot as plt import numpy as np fig, ax = plt.subplots() ax.plot([1, 2, 3]) ax.xaxis.zoom(3) ax.grid() fig.suptitle("""matplotlib.axis.Axis.zoom() function Example\n""", fontweight ="bold") plt.show() Output: Example 2: Python3 # Implementation of matplotlib function from matplotlib.axis import Axis import numpy as np import matplotlib.pyplot as plt from matplotlib.widgets import Slider, Button, RadioButtons fig, ax1 = plt.subplots() plt.subplots_adjust(bottom = 0.25) t = np.arange(0.0, 1.0, 0.001) a0 = 5 f0 = 3 delta_f = 5.0 s = a0 * np.sin(2 * np.pi * f0 * t) ax1.plot(t, s, lw = 2, color = 'green') ax1.xaxis.zoom(-2) ax1.grid() fig.suptitle("""matplotlib.axis.Axis.zoom() function Example\n""", fontweight ="bold") plt.show() Output: Comment More infoAdvertise with us Next Article Matplotlib.axis.Axis.zoom() function in Python S SHUBHAMSINGH10 Follow Improve Article Tags : Python Python-matplotlib Matplotlib-Axis Class Practice Tags : python Similar Reads Matplotlib.axis.Axis.set() function in Python Matplotlib is a library in Python and it is numerical â mathematical extension for NumPy library. It is an amazing visualization library in Python for 2D plots of arrays and used for working with the broader SciPy stack. Matplotlib.axis.Axis.set() Function The Axis.set() function in axis module of m 2 min read Matplotlib.axis.Axis.pan() function in Python Matplotlib is a library in Python and it is numerical â mathematical extension for NumPy library. It is an amazing visualization library in Python for 2D plots of arrays and used for working with the broader SciPy stack. Matplotlib.axis.Axis.pan() Function The Axis.pan() function in axis module of m 2 min read Matplotlib.axis.Axis.cla() function in Python Matplotlib is a library in Python and it is numerical â mathematical extension for NumPy library. It is an amazing visualization library in Python for 2D plots of arrays and used for working with the broader SciPy stack. matplotlib.axis.Axis.cla() Function The Axis.cla() function in axis module of m 1 min read Matplotlib.axis.Axis.update() function in Python Matplotlib is a library in Python and it is numerical â mathematical extension for NumPy library. It is an amazing visualization library in Python for 2D plots of arrays and used for working with the broader SciPy stack. Matplotlib.axis.Axis.update() Function The Axis.update() function in axis modul 2 min read Matplotlib.axis.Axis.draw() function in Python Matplotlib is a library in Python and it is numerical â mathematical extension for NumPy library. It is an amazing visualization library in Python for 2D plots of arrays and used for working with the broader SciPy stack. Matplotlib.axis.Axis.draw() Function The Axis.draw() function in axis module of 1 min read Matplotlib.axes.Axes.can_zoom() in Python Matplotlib is a library in Python and it is numerical - mathematical extension for NumPy library. The Axes Class contains most of the figure elements: Axis, Tick, Line2D, Text, Polygon, etc., and sets the coordinate system. And the instances of Axes supports callbacks through a callbacks attribute. 2 min read Matplotlib.axis.Axis.set_transform() function in Python Matplotlib is a library in Python and it is numerical â mathematical extension for NumPy library. It is an amazing visualization library in Python for 2D plots of arrays and used for working with the broader SciPy stack. Matplotlib.axis.Axis.set_transform() Function The Axis.set_transform() function 2 min read Matplotlib.axis.Axis.get_transform() function in Python Matplotlib is a library in Python and it is numerical â mathematical extension for NumPy library. It is an amazing visualization library in Python for 2D plots of arrays and used for working with the broader SciPy stack. Matplotlib.axis.Axis.get_transform() Function The Axis.get_transform() function 2 min read Matplotlib.axis.Axis.set_units() function in Python Matplotlib is a library in Python and it is numerical â mathematical extension for NumPy library. It is an amazing visualization library in Python for 2D plots of arrays and used for working with the broader SciPy stack. Matplotlib.axis.Axis.set_units() Function The Axis.set_units() function in axis 2 min read Matplotlib.axis.Axis.get_units() function in Python Matplotlib is a library in Python and it is numerical â mathematical extension for NumPy library. It is an amazing visualization library in Python for 2D plots of arrays and used for working with the broader SciPy stack. Matplotlib.axis.Axis.get_units() Function The Axis.get_units() function in axi 2 min read Like