Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit c3dc3a2

Browse filesBrowse files
Backport PR #29617: DOC: Add docstrings to matplotlib.cbook.GrouperView (#29627)
Co-authored-by: Christine P. Chai <star1327p@gmail.com>
1 parent d42384d commit c3dc3a2
Copy full SHA for c3dc3a2

File tree

1 file changed

+12
-2
lines changed
Filter options

1 file changed

+12
-2
lines changed

‎lib/matplotlib/cbook.py

Copy file name to clipboardExpand all lines: lib/matplotlib/cbook.py
+12-2Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -880,8 +880,18 @@ class GrouperView:
880880
def __init__(self, grouper): self._grouper = grouper
881881
def __contains__(self, item): return item in self._grouper
882882
def __iter__(self): return iter(self._grouper)
883-
def joined(self, a, b): return self._grouper.joined(a, b)
884-
def get_siblings(self, a): return self._grouper.get_siblings(a)
883+
884+
def joined(self, a, b):
885+
"""
886+
Return whether *a* and *b* are members of the same set.
887+
"""
888+
return self._grouper.joined(a, b)
889+
890+
def get_siblings(self, a):
891+
"""
892+
Return all of the items joined with *a*, including itself.
893+
"""
894+
return self._grouper.get_siblings(a)
885895

886896

887897
def simple_linear_interpolation(a, steps):

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.