Skip to content

Commit

Permalink
forgot a file
Browse files Browse the repository at this point in the history
  • Loading branch information
FBruzzesi committed Dec 27, 2024
1 parent 6ad961e commit 5c565a4
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion narwhals/_pandas_like/expr.py
Original file line number Diff line number Diff line change
Expand Up @@ -448,9 +448,12 @@ def func(df: PandasLikeDataFrame) -> list[PandasLikeSeries]:
if self._function_name == "col->shift":
kwargs = {"periods": self._kwargs.get("n", 1)}
elif self._function_name == "col->rank":
_method = self._kwargs.get("method", "average")
kwargs = {
"method": self._kwargs.get("method", "average"),
"method": "first" if _method == "ordinal" else _method,
"ascending": not self._kwargs.get("descending", False),
"na_option": "keep",
"pct": False,
}
else: # Cumulative operation
kwargs = {"skipna": True}
Expand Down

0 comments on commit 5c565a4

Please sign in to comment.