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

Method set_position_3d

lib/mpl_toolkits/mplot3d/art3d.py:167–182  ·  view source on GitHub ↗

Set the (*x*, *y*, *z*) position of the text. Parameters ---------- xyz : (float, float, float) The position in 3D space. zdir : {'x', 'y', 'z', None, 3-tuple} The direction of the text. If unspecified, the *zdir* will not be

(self, xyz, zdir=None)

Source from the content-addressed store, hash-verified

165 return self._x, self._y, self._z
166
167 def set_position_3d(self, xyz, zdir=None):
168 """
169 Set the (*x*, *y*, *z*) position of the text.
170
171 Parameters
172 ----------
173 xyz : (float, float, float)
174 The position in 3D space.
175 zdir : {'x', 'y', 'z', None, 3-tuple}
176 The direction of the text. If unspecified, the *zdir* will not be
177 changed. See `.get_dir_vector` for a description of the values.
178 """
179 super().set_position(xyz[:2])
180 self.set_z(xyz[2])
181 if zdir is not None:
182 self._dir_vec = get_dir_vector(zdir)
183
184 def set_z(self, z):
185 """

Callers 1

test_text3d_modificationFunction · 0.80

Calls 3

set_zMethod · 0.95
get_dir_vectorFunction · 0.85
set_positionMethod · 0.45

Tested by 1

test_text3d_modificationFunction · 0.64