3D Axes object. .. note:: As a user, you do not instantiate Axes directly, but use Axes creation methods instead; e.g. from `.pyplot` or `.Figure`: `~.pyplot.subplots`, `~.pyplot.subplot_mosaic` or `.Figure.add_axes`. .. note:: Some of the inherited b
| 62 | @_api.define_aliases({ |
| 63 | "xlim": ["xlim3d"], "ylim": ["ylim3d"], "zlim": ["zlim3d"]}) |
| 64 | class Axes3D(Axes): |
| 65 | """ |
| 66 | 3D Axes object. |
| 67 | |
| 68 | .. note:: |
| 69 | |
| 70 | As a user, you do not instantiate Axes directly, but use Axes creation |
| 71 | methods instead; e.g. from `.pyplot` or `.Figure`: |
| 72 | `~.pyplot.subplots`, `~.pyplot.subplot_mosaic` or `.Figure.add_axes`. |
| 73 | |
| 74 | .. note:: |
| 75 | |
| 76 | Some of the inherited behavior of Axes is not applicable to 3d and will raise |
| 77 | an `.UnsupportedError`. |
| 78 | """ |
| 79 | name = '3d' |
| 80 | |
| 81 | _axis_names = ("x", "y", "z") |
| 82 | Axes._shared_axes["z"] = cbook.Grouper() |
| 83 | Axes._shared_axes["view"] = cbook.Grouper() |
| 84 | |
| 85 | def __init__( |
| 86 | self, fig, rect=None, *args, |
| 87 | elev=30, azim=-60, roll=0, shareview=None, sharez=None, |
| 88 | proj_type='persp', focal_length=None, |
| 89 | box_aspect=None, |
| 90 | computed_zorder=True, |
| 91 | **kwargs, |
| 92 | ): |
| 93 | """ |
| 94 | Parameters |
| 95 | ---------- |
| 96 | fig : Figure |
| 97 | The parent figure. |
| 98 | rect : tuple (left, bottom, width, height), default: (0, 0, 1, 1) |
| 99 | The ``(left, bottom, width, height)`` Axes position. |
| 100 | elev : float, default: 30 |
| 101 | The elevation angle in degrees rotates the camera above and below |
| 102 | the x-y plane, with a positive angle corresponding to a location |
| 103 | above the plane. |
| 104 | azim : float, default: -60 |
| 105 | The azimuthal angle in degrees rotates the camera about the z axis, |
| 106 | with a positive angle corresponding to a right-handed rotation. In |
| 107 | other words, a positive azimuth rotates the camera about the origin |
| 108 | from its location along the +x axis towards the +y axis. |
| 109 | roll : float, default: 0 |
| 110 | The roll angle in degrees rotates the camera about the viewing |
| 111 | axis. A positive angle spins the camera clockwise, causing the |
| 112 | scene to rotate counter-clockwise. |
| 113 | shareview : Axes3D, optional |
| 114 | Other Axes to share view angles with. Note that it is not possible |
| 115 | to unshare axes. |
| 116 | sharez : Axes3D, optional |
| 117 | Other Axes to share z-limits with. Note that it is not possible to |
| 118 | unshare axes. |
| 119 | proj_type : {'persp', 'ortho'} |
| 120 | The projection type, default 'persp'. |
| 121 | focal_length : float, default: None |
searching dependent graphs…