Skip to content

Commit 2cdd5b1

Browse files
committed
Move the entry to API change section and make it prominent
1 parent 705e69c commit 2cdd5b1

File tree

1 file changed

+23
-1
lines changed

1 file changed

+23
-1
lines changed

doc/source/whatsnew/v1.0.0.rst

+23-1
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,28 @@ Backwards incompatible API changes
3939
- :class:`pandas.core.groupby.GroupBy.transform` now raises on invalid operation names (:issue:`27489`).
4040
-
4141

42+
.. _whatsnew_0250.api_breaking.series_string_conversion:
43+
44+
String conversion of Series with nan
45+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
46+
47+
When converting into string, :meth:`Series.astype` will not convert ``np.nan`` into string and keep it as missing value (:issue:`25353`)
48+
49+
*pandas 0.25.x*
50+
51+
.. code-block:: ipython
52+
53+
In [1]: pd.Series(['foo', np.nan]).astype(str)
54+
Out[2]:
55+
0 foo
56+
1 nan
57+
dtype: object
58+
59+
*pandas 1.0.0*
60+
61+
.. ipython:: python
62+
pd.Series(['foo', np.nan]).astype(str)
63+
4264
.. _whatsnew_1000.api.other:
4365

4466
Other API changes
@@ -150,7 +172,7 @@ Indexing
150172
Missing
151173
^^^^^^^
152174

153-
- When converting into string, :meth:`Series.astype` will keep ``np.nan`` as missing value (:issue:`25353`)
175+
-
154176
-
155177

156178
MultiIndex

0 commit comments

Comments
 (0)