Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 753f57b

Browse files
authored
Merge pull request #28370 from anntzer/3do
Reorder Axes3D parameters semantically.
2 parents 62bf05a + 77f60c0 commit 753f57b

File tree

1 file changed

+17
-15
lines changed

1 file changed

+17
-15
lines changed

lib/mpl_toolkits/mplot3d/axes3d.py

Lines changed: 17 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -58,11 +58,13 @@ class Axes3D(Axes):
5858
Axes._shared_axes["view"] = cbook.Grouper()
5959

6060
def __init__(
61-
self, fig, rect=None, *args,
62-
elev=30, azim=-60, roll=0, sharez=None, proj_type='persp',
63-
box_aspect=None, computed_zorder=True, focal_length=None,
64-
shareview=None,
65-
**kwargs):
61+
self, fig, rect=None, *args,
62+
elev=30, azim=-60, roll=0, shareview=None, sharez=None,
63+
proj_type='persp', focal_length=None,
64+
box_aspect=None,
65+
computed_zorder=True,
66+
**kwargs,
67+
):
6668
"""
6769
Parameters
6870
----------
@@ -83,11 +85,21 @@ def __init__(
8385
The roll angle in degrees rotates the camera about the viewing
8486
axis. A positive angle spins the camera clockwise, causing the
8587
scene to rotate counter-clockwise.
88+
shareview : Axes3D, optional
89+
Other Axes to share view angles with. Note that it is not possible
90+
to unshare axes.
8691
sharez : Axes3D, optional
8792
Other Axes to share z-limits with. Note that it is not possible to
8893
unshare axes.
8994
proj_type : {'persp', 'ortho'}
9095
The projection type, default 'persp'.
96+
focal_length : float, default: None
97+
For a projection type of 'persp', the focal length of the virtual
98+
camera. Must be > 0. If None, defaults to 1.
99+
For a projection type of 'ortho', must be set to either None
100+
or infinity (numpy.inf). If None, defaults to infinity.
101+
The focal length can be computed from a desired Field Of View via
102+
the equation: focal_length = 1/tan(FOV/2)
91103
box_aspect : 3-tuple of floats, default: None
92104
Changes the physical dimensions of the Axes3D, such that the ratio
93105
of the axis lengths in display units is x:y:z.
@@ -101,16 +113,6 @@ def __init__(
101113
does not produce the desired result. Note however, that a manual
102114
zorder will only be correct for a limited view angle. If the figure
103115
is rotated by the user, it will look wrong from certain angles.
104-
focal_length : float, default: None
105-
For a projection type of 'persp', the focal length of the virtual
106-
camera. Must be > 0. If None, defaults to 1.
107-
For a projection type of 'ortho', must be set to either None
108-
or infinity (numpy.inf). If None, defaults to infinity.
109-
The focal length can be computed from a desired Field Of View via
110-
the equation: focal_length = 1/tan(FOV/2)
111-
shareview : Axes3D, optional
112-
Other Axes to share view angles with. Note that it is not possible
113-
to unshare axes.
114116
115117
**kwargs
116118
Other optional keyword arguments:

0 commit comments

Comments
 (0)