...

/

The all() Method with Pandas Series

The all() Method with Pandas Series

Let's find out how the all() and any() methods work with pandas series.

We'll cover the following...

Try it yourself

Try executing the code below to see the result.

Press + to interact
import pandas as pd
s = pd.Series([], dtype='float64')
print('full' if s.all() else 'empty')

Explanation

The pandas.Series.all documentation says the following:

  • It returns whether all elements are True, potentially ...