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

Skip to content

Commit aad2986

Browse files
committed
add docstring for set_3d_properties
Also give the zdir a default argument to bring it in line with the other versions of that function.
1 parent a510e32 commit aad2986

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

lib/mpl_toolkits/mplot3d/art3d.py

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -463,7 +463,18 @@ def set_sort_zpos(self, val):
463463
self._sort_zpos = val
464464
self.stale = True
465465

466-
def set_3d_properties(self, zs, zdir):
466+
def set_3d_properties(self, zs, zdir='z'):
467+
"""
468+
Update the z values of the offsets. If there are more XY points in
469+
the offsets than there are Z points then points without a Z offset
470+
will not be drawn.
471+
472+
Parameters
473+
----------
474+
zs : array-like
475+
The new z values for the offsets.
476+
zdir : {'x', 'y', 'z'}, default: 'z'
477+
"""
467478
# Force the collection to initialize the face and edgecolors
468479
# just in case it is a scalarmappable with a colormap.
469480
self.update_scalarmappable()

0 commit comments

Comments
 (0)