You are viewing documentation about an older version (1.21.0). View latest version

modin.pandas.Index.all¶

Index.all(*args, **kwargs) → bool | ExtensionArray[source]¶

Return whether all elements are Truthy.

Parameters:
  • *args (Any) – Required for compatibility with numpy.

  • **kwargs (Any) – Required for compatibility with numpy.

Returns:

A single element array-like may be converted to bool.

Return type:

bool or array-like (if axis is specified)

See also

Index.any

Return whether any element in an Index is True.

Series.any

Return whether any element in a Series is True.

Series.all

Return whether all elements in a Series are True.

Notes

Not a Number (NaN), positive infinity and negative infinity evaluate to True because these are not equal to zero. *args and **kwargs are present for compatibility with numpy and not used with Snowpark pandas.

Examples

True, because nonzero integers are considered True.

>>> pd.Index([1, 2, 3]).all()
True
Copy

False, because 0 is considered False.

>>> pd.Index([0, 1, 2]).all()
False
Copy