diff --git a/pandas/core/ops/array_ops.py b/pandas/core/ops/array_ops.py index 7b21772b443f6..1d08650e23bfd 100644 --- a/pandas/core/ops/array_ops.py +++ b/pandas/core/ops/array_ops.py @@ -129,6 +129,7 @@ def comp_method_OBJECT_ARRAY(op, x, y): result = libops.vec_compare(x.ravel(), y.ravel(), op) else: result = libops.scalar_compare(x.ravel(), y, op) + result = np.where(isna(x), x, result) return result.reshape(x.shape)