Skip to content

Commit

Permalink
FEAT change groupby bfill and ffill from defaulting to Pandas (modin-…
Browse files Browse the repository at this point in the history
…project#72)

also revert `_check_index_name` change from 6c82427

[please upstream to modin-project/modin]
  • Loading branch information
mdatre authored and vnlitvinov committed Mar 16, 2023
1 parent de93072 commit ba1823b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions modin/pandas/groupby.py
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ def skew(self, *args, **kwargs):
)

def ffill(self, limit=None):
return self._default_to_pandas(lambda df: df.ffill(limit=limit))
return self.fillna(limit=limit, method='ffill')

def sem(self, ddof=1):
return self._wrap_aggregation(
Expand Down Expand Up @@ -605,7 +605,7 @@ def cummin(self, axis=0, **kwargs):
)

def bfill(self, limit=None):
return self._default_to_pandas(lambda df: df.bfill(limit=limit))
return self.fillna(limit=limit, method='bfill')

def idxmin(self):
return self._default_to_pandas(lambda df: df.idxmin())
Expand Down Expand Up @@ -774,7 +774,7 @@ def corrwith(self):
return self._default_to_pandas(lambda df: df.corrwith)

def pad(self, limit=None):
return self._default_to_pandas(lambda df: df.pad(limit=limit))
return self.fillna(limit=limit, method='pad')

def max(self, numeric_only=False, min_count=-1):
return self._wrap_aggregation(
Expand Down Expand Up @@ -964,7 +964,7 @@ def fillna(self, *args, **kwargs):
squeeze=self._squeeze,
**new_groupby_kwargs,
)
return work_object._check_index(
return work_object._check_index_name(
work_object._wrap_aggregation(
type(self._query_compiler).groupby_fillna,
numeric_only=False,
Expand Down

0 comments on commit ba1823b

Please sign in to comment.