W3cubDocs

/Matplotlib 3.5

matplotlib.axes.Axes.update_datalim

Axes.update_datalim(xys, updatex=True, updatey=True)[source]

Extend the dataLim Bbox to include the given points.

If no data is set currently, the Bbox will ignore its limits and set the bound to be the bounds of the xydata (xys). Otherwise, it will compute the bounds of the union of its current data and the data in xys.

Parameters
xys2D array-like

The points to include in the data limits Bbox. This can be either a list of (x, y) tuples or a Nx2 array.

updatex, updateybool, default: True

Whether to update the x/y limits.

© 2012–2021 Matplotlib Development Team. All rights reserved.
Licensed under the Matplotlib License Agreement.
https://matplotlib.org/3.5.1/api/_as_gen/matplotlib.axes.Axes.update_datalim.html