Skip to content

Commit 91e590f

Browse files
Merge pull request pandas-dev#8755 from jorisvandenbossche/doc-fixes2
DOC: clean-up v0.15.1 whatsnew file
2 parents 94c91af + dcb4247 commit 91e590f

File tree

1 file changed

+86
-99
lines changed

1 file changed

+86
-99
lines changed

doc/source/whatsnew/v0.15.1.txt

+86-99
Original file line numberDiff line numberDiff line change
@@ -16,29 +16,32 @@ users upgrade to this version.
1616
API changes
1717
~~~~~~~~~~~
1818

19-
- Represent ``MultiIndex`` labels with a dtype that utilizes memory based on the level size. In prior versions, the memory usage was a constant 8 bytes per element in each level. In addition, in prior versions, the *reported* memory usage was incorrect as it didn't show the usage for the memory occupied by the underling data array. (:issue:`8456`)
19+
- ``s.dt.hour`` and other ``.dt`` accessors will now return ``np.nan`` for missing values (rather than previously -1), (:issue:`8689`)
2020

2121
.. ipython:: python
2222

23-
dfi = DataFrame(1,index=pd.MultiIndex.from_product([['a'],range(1000)]),columns=['A'])
23+
s = Series(date_range('20130101',periods=5,freq='D'))
24+
s.iloc[2] = np.nan
25+
s
2426

2527
previous behavior:
2628

2729
.. code-block:: python
2830

29-
# this was underreported in prior versions
30-
In [1]: dfi.memory_usage(index=True)
31-
Out[1]:
32-
Index 8000 # took about 24008 bytes in < 0.15.1
33-
A 8000
31+
In [6]: s.dt.hour
32+
Out[6]:
33+
0 0
34+
1 0
35+
2 -1
36+
3 0
37+
4 0
3438
dtype: int64
3539

36-
3740
current behavior:
3841

3942
.. ipython:: python
4043

41-
dfi.memory_usage(index=True)
44+
s.dt.hour
4245

4346
- ``groupby`` with ``as_index=False`` will not add erroneous extra columns to
4447
result (:issue:`8582`):
@@ -95,56 +98,7 @@ API changes
9598

9699
gr.apply(sum)
97100

98-
- ``concat`` permits a wider variety of iterables of pandas objects to be
99-
passed as the first parameter (:issue:`8645`):
100-
101-
.. ipython:: python
102-
103-
from collections import deque
104-
df1 = pd.DataFrame([1, 2, 3])
105-
df2 = pd.DataFrame([4, 5, 6])
106-
107-
previous behavior:
108-
109-
.. code-block:: python
110-
111-
In [7]: pd.concat(deque((df1, df2)))
112-
TypeError: first argument must be a list-like of pandas objects, you passed an object of type "deque"
113-
114-
current behavior:
115-
116-
.. ipython:: python
117-
118-
pd.concat(deque((df1, df2)))
119-
120-
- ``s.dt.hour`` and other ``.dt`` accessors will now return ``np.nan`` for missing values (rather than previously -1), (:issue:`8689`)
121-
122-
.. ipython:: python
123-
124-
s = Series(date_range('20130101',periods=5,freq='D'))
125-
s.iloc[2] = np.nan
126-
s
127-
128-
previous behavior:
129-
130-
.. code-block:: python
131-
132-
In [6]: s.dt.hour
133-
Out[6]:
134-
0 0
135-
1 0
136-
2 -1
137-
3 0
138-
4 0
139-
dtype: int64
140-
141-
current behavior:
142-
143-
.. ipython:: python
144-
145-
s.dt.hour
146-
147-
- support for slicing with monotonic decreasing indexes, even if ``start`` or ``stop`` is
101+
- Support for slicing with monotonic decreasing indexes, even if ``start`` or ``stop`` is
148102
not found in the index (:issue:`7860`):
149103

150104
.. ipython:: python
@@ -165,14 +119,14 @@ API changes
165119

166120
s.loc[3.5:1.5]
167121

168-
- added Index properties `is_monotonic_increasing` and `is_monotonic_decreasing` (:issue:`8680`).
169122

123+
- ``io.data.Options`` has been fixed for a change in the format of the Yahoo Options page (:issue:`8612`), (:issue:`8741`)
170124

171-
.. note:: io.data.Options has been fixed for a change in the format of the Yahoo Options page (:issue:`8612`), (:issue:`8741`)
125+
.. note::
172126

173-
As a result of a change in Yahoo's option page layout, when an expiry date is given,
174-
``Options`` methods now return data for a single expiry date. Previously, methods returned all
175-
data for the selected month.
127+
As a result of a change in Yahoo's option page layout, when an expiry date is given,
128+
``Options`` methods now return data for a single expiry date. Previously, methods returned all
129+
data for the selected month.
176130

177131
The ``month`` and ``year`` parameters have been undeprecated and can be used to get all
178132
options data for a given month.
@@ -185,11 +139,11 @@ API changes
185139

186140
New features:
187141

188-
The expiry parameter can now be a single date or a list-like object containing dates.
142+
- The expiry parameter can now be a single date or a list-like object containing dates.
189143

190-
A new property ``expiry_dates`` was added, which returns all available expiry dates.
144+
- A new property ``expiry_dates`` was added, which returns all available expiry dates.
191145

192-
current behavior:
146+
Current behavior:
193147

194148
.. ipython:: python
195149

@@ -215,16 +169,78 @@ API changes
215169
Enhancements
216170
~~~~~~~~~~~~
217171

172+
- ``concat`` permits a wider variety of iterables of pandas objects to be
173+
passed as the first parameter (:issue:`8645`):
174+
175+
.. ipython:: python
176+
177+
from collections import deque
178+
df1 = pd.DataFrame([1, 2, 3])
179+
df2 = pd.DataFrame([4, 5, 6])
180+
181+
previous behavior:
182+
183+
.. code-block:: python
184+
185+
In [7]: pd.concat(deque((df1, df2)))
186+
TypeError: first argument must be a list-like of pandas objects, you passed an object of type "deque"
187+
188+
current behavior:
189+
190+
.. ipython:: python
191+
192+
pd.concat(deque((df1, df2)))
193+
194+
- Represent ``MultiIndex`` labels with a dtype that utilizes memory based on the level size. In prior versions, the memory usage was a constant 8 bytes per element in each level. In addition, in prior versions, the *reported* memory usage was incorrect as it didn't show the usage for the memory occupied by the underling data array. (:issue:`8456`)
195+
196+
.. ipython:: python
197+
198+
dfi = DataFrame(1,index=pd.MultiIndex.from_product([['a'],range(1000)]),columns=['A'])
199+
200+
previous behavior:
201+
202+
.. code-block:: python
203+
204+
# this was underreported in prior versions
205+
In [1]: dfi.memory_usage(index=True)
206+
Out[1]:
207+
Index 8000 # took about 24008 bytes in < 0.15.1
208+
A 8000
209+
dtype: int64
210+
211+
212+
current behavior:
213+
214+
.. ipython:: python
215+
216+
dfi.memory_usage(index=True)
217+
218+
- Added Index properties `is_monotonic_increasing` and `is_monotonic_decreasing` (:issue:`8680`).
219+
218220
- Added option to select columns when importing Stata files (:issue:`7935`)
221+
219222
- Qualify memory usage in ``DataFrame.info()`` by adding ``+`` if it is a lower bound (:issue:`8578`)
223+
220224
- Raise errors in certain aggregation cases where an argument such as ``numeric_only`` is not handled (:issue:`8592`).
221225

226+
- Added support for 3-character ISO and non-standard country codes in :func:`io.wb.download()` (:issue:`8482`)
227+
228+
- :ref:`World Bank data requests <remote_data.wb>` now will warn/raise based
229+
on an ``errors`` argument, as well as a list of hard-coded country codes and
230+
the World Bank's JSON response. In prior versions, the error messages
231+
didn't look at the World Bank's JSON response. Problem-inducing input were
232+
simply dropped prior to the request. The issue was that many good countries
233+
were cropped in the hard-coded approach. All countries will work now, but
234+
some bad countries will raise exceptions because some edge cases break the
235+
entire response. (:issue:`8482`)
222236

223-
- Added support for 3-character ISO and non-standard country codes in :func:``io.wb.download()`` (:issue:`8482`)
224-
- :ref:`World Bank data requests <remote_data.wb>` now will warn/raise based on an ``errors`` argument, as well as a list of hard-coded country codes and the World Bank's JSON response. In prior versions, the error messages didn't look at the World Bank's JSON response. Problem-inducing input were simply dropped prior to the request. The issue was that many good countries were cropped in the hard-coded approach. All countries will work now, but some bad countries will raise exceptions because some edge cases break the entire response. (:issue:`8482`)
225237
- Added option to ``Series.str.split()`` to return a ``DataFrame`` rather than a ``Series`` (:issue:`8428`)
238+
226239
- Added option to ``df.info(null_counts=None|True|False)`` to override the default display options and force showing of the null-counts (:issue:`8701`)
227240

241+
242+
.. _whatsnew_0151.bug_fixes:
243+
228244
Bug Fixes
229245
~~~~~~~~~
230246

@@ -243,48 +259,19 @@ Bug Fixes
243259
- Compat issue is ``DataFrame.dtypes`` when ``options.mode.use_inf_as_null`` is True (:issue:`8722`)
244260
- Bug in ``read_csv``, ``dialect`` parameter would not take a string (:issue: `8703`)
245261
- Bug in slicing a multi-index level with an empty-list (:issue:`8737`)
246-
247-
248-
249-
250-
251262
- Bug in numeric index operations of add/sub with Float/Index Index with numpy arrays (:issue:`8608`)
252263
- Bug in setitem with empty indexer and unwanted coercion of dtypes (:issue:`8669`)
253-
254-
255-
256-
257-
258-
259-
260264
- Bug in ix/loc block splitting on setitem (manifests with integer-like dtypes, e.g. datetime64) (:issue:`8607`)
261-
262-
263265
- Bug when doing label based indexing with integers not found in the index for
264266
non-unique but monotonic indexes (:issue:`8680`).
265267
- Bug when indexing a Float64Index with ``np.nan`` on numpy 1.7 (:issue:`8980`).
266-
267-
268-
269-
270-
271-
272-
273-
274-
275-
276268
- Fix ``shape`` attribute for ``MultiIndex`` (:issue:`8609`)
277269
- Bug in ``GroupBy`` where a name conflict between the grouper and columns
278270
would break ``groupby`` operations (:issue:`7115`, :issue:`8112`)
279-
280-
281-
282271
- Fixed a bug where plotting a column ``y`` and specifying a label would mutate the index name of the original DataFrame (:issue:`8494`)
283272
- Fix regression in plotting of a DatetimeIndex directly with matplotlib (:issue:`8614`).
284-
285273
- Bug in ``date_range`` where partially-specified dates would incorporate current date (:issue:`6961`)
286-
287274
- Bug in Setting by indexer to a scalar value with a mixed-dtype `Panel4d` was failing (:issue:`8702`)
288-
289275
- Bug where ``DataReader``'s would fail if one of the symbols passed was invalid. Now returns data for valid symbols and np.nan for invalid (:issue:`8494`)
290276
- Bug in ``get_quote_yahoo`` that wouldn't allow non-float return values (:issue:`5229`).
277+

0 commit comments

Comments
 (0)