idxmin(self, axis=0, skipna=True, *args, **kwargs)
If multiple values equal the minimum, the first row label with that value is returned.
This method is the Series version of ndarray.argmin
. This method returns the label of the minimum, while ndarray.argmin
returns the position. To get the position, use series.values.argmin()
.
For compatibility with DataFrame.idxmin. Redundant for application on Series.
Exclude NA/null values. If the entire Series is NA, the result will be NA.
Additional arguments and keywords have no effect but might be accepted for compatibility with NumPy.
If the Series is empty.
Label of the minimum value.
Return the row label of the minimum value.
DataFrame.idxmin
Return index of first occurrence of minimum over requested axis.
Series.idxmax
Return index label of the first occurrence of maximum of values.
numpy.argmin
Return indices of the minimum values along the given axis.
>>> s = pd.Series(data=[1, None, 4, 1],This example is valid syntax, but we were not able to check execution
... index=['A', 'B', 'C', 'D'])
... s A 1.0 B NaN C 4.0 D 1.0 dtype: float64
>>> s.idxmin() 'A'
If :None:None:`skipna`
is False and there is an NA value in the data, the function returns nan
.
>>> s.idxmin(skipna=False) nanSee :
The following pages refer to to this document either explicitly or contain code examples using this.
pandas.core.base.IndexOpsMixin.argmin
pandas.core.generic.NDFrame._add_numeric_operations.<locals>.prod
pandas.core.series.Series.idxmax
pandas.core.generic.NDFrame._add_numeric_operations.<locals>.sum
pandas.core.base.IndexOpsMixin.argmax
pandas.core.generic.NDFrame._add_numeric_operations.<locals>.min
pandas.core.groupby.generic.DataFrameGroupBy.idxmin
pandas.core.indexes.base.Index.argmax
pandas.core.frame.DataFrame.idxmin
pandas.core.generic.NDFrame._add_numeric_operations.<locals>.max
pandas.core.indexes.base.Index.argmin
Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.
Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)
SVG is more flexible but power hungry; and does not scale well to 50 + nodes.
All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them