You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- All ``offsets`` suppports ``normalize`` keyword to specify whether ``offsets.apply``, ``rollforward`` and ``rollback`` resets time (hour, minute, etc) or not (default ``False``, preserves time) (:issue:`7156`)
28
-
29
-
30
-
.. ipython:: python
31
-
32
-
import pandas.tseries.offsets as offsets
33
-
34
-
day = offsets.Day()
35
-
day.apply(Timestamp('2014-01-01 09:00'))
36
-
37
-
day = offsets.Day(normalize=True)
38
-
day.apply(Timestamp('2014-01-01 09:00'))
39
-
40
-
- Improved inference of datetime/timedelta with mixed null objects. Regression from 0.13.1 in interpretation of an object Index
41
-
with all null elements (:issue:`7431`)
42
-
43
32
- Openpyxl now raises a ValueError on construction of the openpyxl writer
44
33
instead of warning on pandas import (:issue:`7284`).
45
34
46
35
- For ``StringMethods.extract``, when no match is found, the result - only
47
36
containing ``NaN`` values - now also has ``dtype=object`` instead of
48
37
``float`` (:issue:`7242`)
49
38
50
-
- ``StringMethods`` now work on empty Series (:issue:`7242`)
51
39
- ``Period`` objects no longer raise a ``TypeError`` when compared using ``==``
52
40
with another object that *isn't* a ``Period``. Instead
53
41
when comparing a ``Period`` with another object using ``==`` if the other
54
42
object isn't a ``Period`` ``False`` is returned. (:issue:`7376`)
55
43
56
-
- Bug in ``.loc`` performing fallback integer indexing with ``object`` dtype indices (:issue:`7496`)
57
-
- Add back ``#N/A N/A`` as a default NA value in text parsing, (regresion from 0.12) (:issue:`5521`)
58
-
- Raise a ``TypeError`` on inplace-setting with a ``.where`` and a non ``np.nan`` value as this is inconsistent
59
-
with a set-item expression like ``df[mask] = None`` (:issue:`7656`)
60
-
61
-
.. _whatsnew_0141.prior_deprecations:
62
-
63
-
Prior Version Deprecations/Changes
64
-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
44
+
- Previously, the behaviour on resetting the time or not in
45
+
``offsets.apply``, ``rollforward`` and ``rollback`` operations differed
46
+
between offsets. With the support of the ``normalize`` keyword for all offsets(see
47
+
below) with a default value of False (preserve time), the behaviour changed for certain
There are no prior version deprecations that are taking effect as of 0.14.1.
51
+
.. code-block:: python
67
52
68
-
.. _whatsnew_0141.deprecations:
53
+
In [6]: from pandas.tseries import offsets
69
54
70
-
Deprecations
71
-
~~~~~~~~~~~~
55
+
In [7]: d = pd.Timestamp('2014-01-01 09:00')
72
56
73
-
There are no deprecations that are taking effect as of 0.14.1.
57
+
# old behaviour < 0.14.1
58
+
In [8]: d + offsets.MonthEnd()
59
+
Out[8]: Timestamp('2014-01-31 00:00:00')
74
60
75
-
.. _whatsnew_0141.enhancements:
76
-
77
-
Enhancements
78
-
~~~~~~~~~~~~
79
-
80
-
81
-
82
-
- Add ``dropna`` argument to ``value_counts`` and ``nunique`` (:issue:`5569`).
83
-
- Add ``NotImplementedError`` for simultaneous use of ``chunksize`` and ``nrows``
84
-
for read_csv() (:issue:`6774`).
61
+
Starting from 0.14.1 all offsets preserve time by default. The old
62
+
behaviour can be obtained with ``normalize=True``
85
63
86
-
- ``PeriodIndex`` is represented as the same format as ``DatetimeIndex`` (:issue:`7601`)
64
+
.. ipython:: python
65
+
:suppress:
87
66
67
+
import pandas.tseries.offsets as offsets
68
+
d = pd.Timestamp('2014-01-01 09:00')
88
69
70
+
.. ipython:: python
89
71
72
+
# new behaviour
73
+
d + offsets.MonthEnd()
74
+
d + offsets.MonthEnd(normalize=True)
90
75
76
+
Note that for the other offsets the default behaviour did not change.
91
77
78
+
- Add back ``#N/A N/A`` as a default NA value in text parsing, (regresion from 0.12) (:issue:`5521`)
79
+
- Raise a ``TypeError`` on inplace-setting with a ``.where`` and a non ``np.nan`` value as this is inconsistent
80
+
with a set-item expression like ``df[mask] = None`` (:issue:`7656`)
92
81
93
82
83
+
.. _whatsnew_0141.enhancements:
94
84
85
+
Enhancements
86
+
~~~~~~~~~~~~
95
87
88
+
- Add ``dropna`` argument to ``value_counts`` and ``nunique`` (:issue:`5569`).
96
89
- Add :meth:`~pandas.DataFrame.select_dtypes` method to allow selection of
97
90
columns based on dtype (:issue:`7316`). See :ref:`the docs <basics.selectdtypes>`.
91
+
- All ``offsets`` suppports the ``normalize`` keyword to specify whether
92
+
``offsets.apply``, ``rollforward`` and ``rollback`` resets the time (hour,
93
+
minute, etc) or not (default ``False``, preserves time) (:issue:`7156`):
98
94
95
+
.. ipython:: python
99
96
97
+
import pandas.tseries.offsets as offsets
100
98
99
+
day = offsets.Day()
100
+
day.apply(Timestamp('2014-01-01 09:00'))
101
+
102
+
day = offsets.Day(normalize=True)
103
+
day.apply(Timestamp('2014-01-01 09:00'))
104
+
105
+
- ``PeriodIndex`` is represented as the same format as ``DatetimeIndex`` (:issue:`7601`)
106
+
- ``StringMethods`` now work on empty Series (:issue:`7242`)
101
107
- The file parsers ``read_csv`` and ``read_table`` now ignore line comments provided by
102
108
the parameter `comment`, which accepts only a single character for the C reader.
103
109
In particular, they allow for comments before file data begins (:issue:`2685`)
110
+
- Add ``NotImplementedError`` for simultaneous use of ``chunksize`` and ``nrows``
111
+
for read_csv() (:issue:`6774`).
104
112
- Tests for basic reading of public S3 buckets now exist (:issue:`7281`).
105
113
- ``read_html`` now sports an ``encoding`` argument that is passed to the
106
114
underlying parser library. You can use this to read non-ascii encoded web
107
115
pages (:issue:`7323`).
108
116
- ``read_excel`` now supports reading from URLs in the same way
109
117
that ``read_csv`` does. (:issue:`6809`)
110
-
111
-
112
118
- Support for dateutil timezones, which can now be used in the same way as
113
119
pytz timezones across pandas. (:issue:`4688`)
114
120
@@ -125,16 +131,13 @@ Enhancements
125
131
- Add ``nlargest`` and ``nsmallest`` to the ``Series`` ``groupby`` whitelist,
126
132
which means you can now use these methods on a ``SeriesGroupBy`` object
127
133
(:issue:`7053`).
128
-
129
-
130
-
131
134
- All offsets ``apply``, ``rollforward`` and ``rollback`` can now handle ``np.datetime64``, previously results in ``ApplyTypeError`` (:issue:`7452`)
132
-
133
135
- ``Period`` and ``PeriodIndex`` can contain ``NaT`` in its values (:issue:`7485`)
134
136
- Support pickling ``Series``, ``DataFrame`` and ``Panel`` objects with
135
137
non-unique labels along *item* axis (``index``, ``columns`` and ``items``
136
138
respectively) (:issue:`7370`).
137
-
139
+
- Improved inference of datetime/timedelta with mixed null objects. Regression from 0.13.1 in interpretation of an object Index
140
+
with all null elements (:issue:`7431`)
138
141
139
142
.. _whatsnew_0141.performance:
140
143
@@ -147,25 +150,20 @@ Performance
147
150
- Improvements in `MultiIndex.from_product` for large iterables (:issue:`7627`)
148
151
149
152
150
-
151
153
.. _whatsnew_0141.experimental:
152
154
153
-
154
-
155
-
156
-
157
155
Experimental
158
156
~~~~~~~~~~~~
159
157
160
158
- ``pandas.io.data.Options`` has a new method, ``get_all_data`` method, and now consistently returns a
161
159
multi-indexed ``DataFrame``, see :ref:`the docs <remote_data.yahoo_options>`. (:issue:`5602`)
162
-
163
160
- ``io.gbq.read_gbq`` and ``io.gbq.to_gbq`` were refactored to remove the
164
161
dependency on the Google ``bq.py`` command line client. This submodule
165
162
now uses ``httplib2`` and the Google ``apiclient`` and ``oauth2client`` API client
166
163
libraries which should be more stable and, therefore, reliable than
167
164
``bq.py``. See :ref:`the docs <io.bigquery>`. (:issue:`6937`).
168
165
166
+
169
167
.. _whatsnew_0141.bug_fixes:
170
168
171
169
Bug Fixes
@@ -185,10 +183,7 @@ Bug Fixes
185
183
- Bug in plotting subplots with ``DataFrame.plot``, ``hist`` clears passed ``ax`` even if the number of subplots is one (:issue:`7391`).
186
184
- Bug in plotting subplots with ``DataFrame.boxplot`` with ``by`` kw raises ``ValueError`` if the number of subplots exceeds 1 (:issue:`7391`).
187
185
- Bug in subplots displays ``ticklabels`` and ``labels`` in different rule (:issue:`5897`)
188
-
189
186
- Bug in ``Panel.apply`` with a multi-index as an axis (:issue:`7469`)
190
-
191
-
192
187
- Bug in ``DatetimeIndex.insert`` doesn't preserve ``name`` and ``tz`` (:issue:`7299`)
193
188
- Bug in ``DatetimeIndex.asobject`` doesn't preserve ``name`` (:issue:`7299`)
194
189
- Bug in multi-index slicing with datetimelike ranges (strings and Timestamps), (:issue:`7429`)
@@ -246,49 +241,31 @@ Bug Fixes
246
241
- Bug in ``StataReader.data`` where reading a 0-observation dta failed (:issue:`7369`)
247
242
- Bug in when reading Stata 13 (117) files containing fixed width strings (:issue:`7360`)
248
243
- Bug in when writing Stata files where the encoding was ignored (:issue:`7286`)
249
-
250
-
251
244
- Bug in ``DatetimeIndex`` comparison doesn't handle ``NaT`` properly (:issue:`7529`)
252
-
253
-
254
245
- Bug in passing input with ``tzinfo`` to some offsets ``apply``, ``rollforward`` or ``rollback`` resets ``tzinfo`` or raises ``ValueError`` (:issue:`7465`)
255
246
- Bug in ``DatetimeIndex.to_period``, ``PeriodIndex.asobject``, ``PeriodIndex.to_timestamp`` doesn't preserve ``name`` (:issue:`7485`)
256
247
- Bug in ``DatetimeIndex.to_period`` and ``PeriodIndex.to_timestanp`` handle ``NaT`` incorrectly (:issue:`7228`)
257
-
258
248
- Bug in ``offsets.apply``, ``rollforward`` and ``rollback`` may return normal ``datetime`` (:issue:`7502`)
259
-
260
-
261
249
- Bug in ``resample`` raises ``ValueError`` when target contains ``NaT`` (:issue:`7227`)
262
-
263
250
- Bug in ``Timestamp.tz_localize`` resets ``nanosecond`` info (:issue:`7534`)
264
251
- Bug in ``DatetimeIndex.asobject`` raises ``ValueError`` when it contains ``NaT`` (:issue:`7539`)
265
252
- Bug in ``Timestamp.__new__`` doesn't preserve nanosecond properly (:issue:`7610`)
266
-
267
253
- Bug in ``Index.astype(float)`` where it would return an ``object`` dtype
268
254
``Index`` (:issue:`7464`).
269
255
- Bug in ``DataFrame.reset_index`` loses ``tz`` (:issue:`3950`)
270
256
- Bug in ``DatetimeIndex.freqstr`` raises ``AttributeError`` when ``freq`` is ``None`` (:issue:`7606`)
271
257
- Bug in ``GroupBy.size`` created by ``TimeGrouper`` raises ``AttributeError`` (:issue:`7453`)
272
-
273
258
- Bug in single column bar plot is misaligned (:issue:`7498`).
274
-
275
-
276
-
277
259
- Bug in area plot with tz-aware time series raises ``ValueError`` (:issue:`7471`)
278
-
279
260
- Bug in non-monotonic ``Index.union`` may preserve ``name`` incorrectly (:issue:`7458`)
280
261
- Bug in ``DatetimeIndex.intersection`` doesn't preserve timezone (:issue:`4690`)
281
-
282
262
- Bug in ``rolling_var`` where a window larger than the array would raise an error(:issue:`7297`)
283
-
284
263
- Bug with last plotted timeseries dictating ``xlim`` (:issue:`2960`)
285
264
- Bug with ``secondary_y`` axis not being considered for timeseries ``xlim`` (:issue:`3490`)
286
-
287
265
- Bug in ``Float64Index`` assignment with a non scalar indexer (:issue:`7586`)
288
266
- Bug in ``pandas.core.strings.str_contains`` does not properly match in a case insensitive fashion when ``regex=False`` and ``case=False`` (:issue:`7505`)
289
-
290
267
- Bug in ``expanding_cov``, ``expanding_corr``, ``rolling_cov``, and ``rolling_corr`` for two arguments with mismatched index (:issue:`7512`)
291
-
292
268
- Bug in ``to_sql`` taking the boolean column as text column (:issue:`7678`)
293
269
- Bug in grouped `hist` doesn't handle `rot` kw and `sharex` kw properly (:issue:`7234`)
270
+
- Bug in ``.loc`` performing fallback integer indexing with ``object`` dtype indices (:issue:`7496`)
294
271
- Bug (regression) in ``PeriodIndex`` constructor when passed ``Series`` objects (:issue:`7701`).
0 commit comments