Skip to content

Commit f5d5817

Browse files
meeseeksmachineTomAugspurger
authored andcommitted
Backport PR #31015: DOC: Fixed documented value of pd.NA ** 0 (#31005) (#31019)
Co-authored-by: Tom Augspurger <[email protected]>
1 parent 33aaf7d commit f5d5817

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

doc/source/user_guide/missing_data.rst

+3-6
Original file line numberDiff line numberDiff line change
@@ -825,13 +825,10 @@ For example, ``pd.NA`` propagates in arithmetic operations, similarly to
825825
There are a few special cases when the result is known, even when one of the
826826
operands is ``NA``.
827827

828+
.. ipython:: python
828829
829-
================ ======
830-
Operation Result
831-
================ ======
832-
``pd.NA ** 0`` 0
833-
``1 ** pd.NA`` 1
834-
================ ======
830+
pd.NA ** 0
831+
1 ** pd.NA
835832
836833
In equality and comparison operations, ``pd.NA`` also propagates. This deviates
837834
from the behaviour of ``np.nan``, where comparisons with ``np.nan`` always

0 commit comments

Comments
 (0)