Skip to content
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
8 changes: 0 additions & 8 deletions pandas/core/resample.py
Original file line number Diff line number Diff line change
Expand Up @@ -850,7 +850,6 @@ def interpolate(
inplace: bool = False,
limit_direction: Literal["forward", "backward", "both"] = "forward",
limit_area=None,
downcast=lib.no_default,
**kwargs,
):
"""
Expand Down Expand Up @@ -907,11 +906,6 @@ def interpolate(
(interpolate).
* 'outside': Only fill NaNs outside valid values (extrapolate).
downcast : optional, 'infer' or None, defaults to None
Downcast dtypes if possible.
.. deprecated:: 2.1.0
**kwargs : optional
Keyword arguments to pass on to the interpolating function.
Expand Down Expand Up @@ -993,7 +987,6 @@ def interpolate(
Note that the series correctly decreases between two anchors
``07:00:00`` and ``07:00:02``.
"""
assert downcast is lib.no_default # just checking coverage
result = self._upsample("asfreq")

# If the original data has timestamps which are not aligned with the
Expand Down Expand Up @@ -1030,7 +1023,6 @@ def interpolate(
inplace=inplace,
limit_direction=limit_direction,
limit_area=limit_area,
downcast=downcast,
**kwargs,
)

Expand Down
4 changes: 2 additions & 2 deletions pandas/tests/copy_view/test_interp_fillna.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def test_interpolate_object_convert_copies():
arr_a = get_array(df, "a")
msg = "Can not interpolate with method=pad"
with pytest.raises(ValueError, match=msg):
df.interpolate(method="pad", inplace=True, downcast="infer")
df.interpolate(method="pad", inplace=True)

assert df._mgr._has_no_reference(0)
assert np.shares_memory(arr_a, get_array(df, "a"))
Expand All @@ -148,7 +148,7 @@ def test_interpolate_downcast_reference_triggers_copy():

msg = "Can not interpolate with method=pad"
with pytest.raises(ValueError, match=msg):
df.interpolate(method="pad", inplace=True, downcast="infer")
df.interpolate(method="pad", inplace=True)
assert df._mgr._has_no_reference(0)
assert not np.shares_memory(arr_a, get_array(df, "a"))

Expand Down
Loading