Skip to content

Commit 1802ae4

Browse files
DOC: Improved docstring of pandas.index.min()
1 parent 4131149 commit 1802ae4

File tree

1 file changed

+22
-1
lines changed

1 file changed

+22
-1
lines changed

pandas/core/base.py

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -801,7 +801,28 @@ def argmax(self, axis=None):
801801
return nanops.nanargmax(self.values)
802802

803803
def min(self):
804-
""" The minimum value of the object """
804+
"""
805+
Return the minimum value of the Index object.
806+
807+
Returns
808+
-------
809+
scalar or object
810+
minimum value
811+
812+
See Also
813+
--------
814+
Index.max : Return the maximum value of the object.
815+
816+
Examples
817+
--------
818+
>>> idx = pd.Index([3, 2, 1])
819+
>>> idx.min()
820+
1
821+
822+
>>> idx = pd.Index(['c', 'b', 'a'])
823+
>>> idx.min()
824+
'a'
825+
"""
805826
return nanops.nanmin(self.values)
806827

807828
def argmin(self, axis=None):

0 commit comments

Comments
 (0)