polars.Series.is_not_nan#

Series.is_not_nan() Series[source]#

Returns a boolean Series indicating which values are not NaN.

Returns:
Series

Series of data type Boolean.

Examples

>>> import numpy as np
>>> s = pl.Series("a", [1.0, 2.0, 3.0, np.NaN])
>>> s.is_not_nan()
shape: (4,)
Series: 'a' [bool]
[
        true
        true
        true
        false
]