polars.Series.is_infinite#

Series.is_infinite() Series[source]#

Returns a boolean Series indicating which values are infinite.

Returns:
Series

Series of data type Boolean.

Examples

>>> import numpy as np
>>> s = pl.Series("a", [1.0, 2.0, np.inf])
>>> s.is_infinite()
shape: (3,)
Series: 'a' [bool]
[
        false
        false
        true
]