Skip to content

API: deprecate DataFrame.interpolate #3675

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 22, 2013
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion RELEASE.rst
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,9 @@ pandas 0.11.1
- The ``raise_on_error`` option to plotting methods is obviated by GH3572_,
so it is removed. Plots now always raise when data cannot be plotted or the
object being plotted has a dtype of ``object``.
- ``DataFrame.interpolate()`` is now deprecated. Please use
``DataFrame.fillna()`` and ``DataFrame.replace()`` instead (GH3582_,
GH3675_, GH3676_).

**Bug Fixes**

Expand Down Expand Up @@ -233,9 +236,11 @@ pandas 0.11.1
.. _GH3606: https://github.com/pydata/pandas/issues/3606
.. _GH3659: https://github.com/pydata/pandas/issues/3659
.. _GH3649: https://github.com/pydata/pandas/issues/3649
.. _Gh3616: https://github.com/pydata/pandas/issues/3616
.. _GH1818: https://github.com/pydata/pandas/issues/1818
.. _GH3572: https://github.com/pydata/pandas/issues/3572
.. _GH3582: https://github.com/pydata/pandas/issues/3582
.. _GH3676: https://github.com/pydata/pandas/issues/3676
.. _GH3675: https://github.com/pydata/pandas/issues/3675

pandas 0.11.0
=============
Expand Down
6 changes: 6 additions & 0 deletions doc/source/v0.11.1.txt
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,9 @@ API changes
and thus you should cast to an appropriate numeric dtype if you need to
plot something.

- ``DataFrame.interpolate()`` is now deprecated. Please use
``DataFrame.fillna()`` and ``DataFrame.replace()`` instead. (GH3582_,
GH3675_, GH3676_)


Enhancements
Expand Down Expand Up @@ -241,3 +244,6 @@ on GitHub for a complete list.
.. _GH3656: https://github.com/pydata/pandas/issues/3656
.. _GH1818: https://github.com/pydata/pandas/issues/1818
.. _GH3572: https://github.com/pydata/pandas/issues/3572
.. _GH3582: https://github.com/pydata/pandas/issues/3582
.. _GH3676: https://github.com/pydata/pandas/issues/3676
.. _GH3675: https://github.com/pydata/pandas/issues/3675
6 changes: 5 additions & 1 deletion pandas/core/frame.py
Original file line number Diff line number Diff line change
Expand Up @@ -3506,7 +3506,7 @@ def replace(self, to_replace=None, value=None, method='pad', axis=0,

See also
--------
reindex, asfreq, fillna, interpolate
reindex, asfreq, fillna

Returns
-------
Expand Down Expand Up @@ -3678,6 +3678,10 @@ def interpolate(self, to_replace, method='pad', axis=0, inplace=False,
--------
reindex, replace, fillna
"""
from warnings import warn
warn('DataFrame.interpolate will be removed in v0.12, please use '
'either DataFrame.fillna or DataFrame.replace instead',
FutureWarning)
if self._is_mixed_type and axis == 1:
return self.T.replace(to_replace, method=method, limit=limit).T

Expand Down