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

Method set_xlim

lib/mpl_toolkits/mplot3d/axes3d.py:876–947  ·  view source on GitHub ↗

Set the 3D x-axis view limits. Parameters ---------- left : float, optional The left xlim in data coordinates. Passing *None* leaves the limit unchanged. The left and right xlims may also be passed as the tuple (*left

(self, left=None, right=None, *, emit=True, auto=False,
                 view_margin=None, xmin=None, xmax=None)

Source from the content-addressed store, hash-verified

874 return axis._set_lim(lower, upper, emit=emit, auto=auto)
875
876 def set_xlim(self, left=None, right=None, *, emit=True, auto=False,
877 view_margin=None, xmin=None, xmax=None):
878 """
879 Set the 3D x-axis view limits.
880
881 Parameters
882 ----------
883 left : float, optional
884 The left xlim in data coordinates. Passing *None* leaves the
885 limit unchanged.
886
887 The left and right xlims may also be passed as the tuple
888 (*left*, *right*) as the first positional argument (or as
889 the *left* keyword argument).
890
891 .. ACCEPTS: (left: float, right: float)
892
893 right : float, optional
894 The right xlim in data coordinates. Passing *None* leaves the
895 limit unchanged.
896
897 emit : bool, default: True
898 Whether to notify observers of limit change.
899
900 auto : bool or None, default: False
901 Whether to turn on autoscaling of the x-axis. *True* turns on,
902 *False* turns off, *None* leaves unchanged.
903
904 view_margin : float, optional
905 The additional margin to apply to the limits.
906
907 xmin, xmax : float, optional
908 They are equivalent to left and right respectively, and it is an
909 error to pass both *xmin* and *left* or *xmax* and *right*.
910
911 Returns
912 -------
913 left, right : (float, float)
914 The new x-axis limits in data coordinates.
915
916 See Also
917 --------
918 get_xlim
919 set_xbound, get_xbound
920 invert_xaxis, xaxis_inverted
921
922 Notes
923 -----
924 The *left* value may be greater than the *right* value, in which
925 case the x-axis values will decrease from *left* to *right*.
926
927 Examples
928 --------
929 >>> set_xlim(left, right)
930 >>> set_xlim((left, right))
931 >>> left, right = set_xlim(left, right)
932
933 One limit may be left unchanged.

Callers 15

test_contour3d_extend3dFunction · 0.45
test_contourf3dFunction · 0.45
test_contourf3d_fillFunction · 0.45
test_contourf3d_extendFunction · 0.45
test_quiver3dFunction · 0.45
test_proj_axes_cubeFunction · 0.45
test_inverted_claFunction · 0.45
test_ticklabel_formatFunction · 0.45
test_computed_zorderFunction · 0.45

Calls 1

_set_lim3dMethod · 0.95

Tested by 15

test_contour3d_extend3dFunction · 0.36
test_contourf3dFunction · 0.36
test_contourf3d_fillFunction · 0.36
test_contourf3d_extendFunction · 0.36
test_quiver3dFunction · 0.36
test_proj_axes_cubeFunction · 0.36
test_inverted_claFunction · 0.36
test_ticklabel_formatFunction · 0.36
test_computed_zorderFunction · 0.36