ak.nan_to_num¶
Defined in awkward.operations.structure on line 4483.
- ak.nan_to_num(array, copy=True, nan=0.0, posinf=None, neginf=None, highlevel=True, behavior=None)¶
- Parameters
array – Array whose
NaN
values should be converted to a number.copy (bool) – Ignored (Awkward Arrays are immutable).
nan (int, float, broadcastable array) – Value to be used to fill
NaN
values.posinf (None, int, float, broadcastable array) – Value to be used to fill positive infinity values. If None, positive infinities are replaced with a very large number.
neginf (None, int, float, broadcastable array) – Value to be used to fill negative infinity values. If None, negative infinities are replaced with a very small number.
highlevel (bool) – If True, return an
ak.Array
; otherwise, return a low-levelak.layout.Content
subclass.behavior (None or dict) – Custom
ak.behavior
for the output array, if high-level.
Implements np.nan_to_num for Awkward Arrays.