frlearn.array_functions.div_or

frlearn.array_functions.div_or(x: array, y: array, fallback: array = nan)[source]

Divides x by y, replacing np.nan values with fallback.

Parameters
x: np.array or float

Dividend.

y: np.array or float

Divisor.

fallback: np.array or float, default=np.nan

Fallback value(s) to substitute for np.nan after division.

Returns
z: np.array

Quotient.

Notes

x, y and fallback should be broadcastable to a single shape.