From 93233c5eda7f77edbeac982def40ef41814d6e52 Mon Sep 17 00:00:00 2001 From: tsvikas Date: Tue, 14 Jan 2020 22:28:49 +0200 Subject: [PATCH] DOC: Fixed documented value of `pd.NA ** 0` (#31005) (cherry picked from commit da04c9a8fe6ddbc7028e8721c57d3e62d1da11e3) --- doc/source/user_guide/missing_data.rst | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/doc/source/user_guide/missing_data.rst b/doc/source/user_guide/missing_data.rst index df9949e8ac261..0f55980b3d015 100644 --- a/doc/source/user_guide/missing_data.rst +++ b/doc/source/user_guide/missing_data.rst @@ -825,13 +825,10 @@ For example, ``pd.NA`` propagates in arithmetic operations, similarly to There are a few special cases when the result is known, even when one of the operands is ``NA``. +.. ipython:: python -================ ====== -Operation Result -================ ====== -``pd.NA ** 0`` 0 -``1 ** pd.NA`` 1 -================ ====== + pd.NA ** 0 + 1 ** pd.NA In equality and comparison operations, ``pd.NA`` also propagates. This deviates from the behaviour of ``np.nan``, where comparisons with ``np.nan`` always