You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "devin-petersohn (via GitHub)" <gi...@apache.org> on 2026/02/05 21:22:36 UTC
Re: [PR] [SPARK-46167][PS] Add axis implementation to DataFrame.rank [spark]
devin-petersohn commented on code in PR #54009:
URL: https://github.com/apache/spark/pull/54009#discussion_r2771214858
##########
python/pyspark/pandas/frame.py:
##########
@@ -11361,9 +11361,13 @@ def _result_aggregated(
# dtype: bool
return first_series(DataFrame(internal))
- # TODO(SPARK-46167): add axis, pct, na_option parameter
+ # TODO(SPARK-46167): add pct, na_option parameter
def rank(
- self, method: str = "average", ascending: bool = True, numeric_only: bool = False
+ self,
+ method: str = "average",
+ ascending: bool = True,
+ numeric_only: bool = False,
+ axis: Axis = 0,
Review Comment:
@HyukjinKwon do you have any thoughts on this? I added the Axis argument last to avoid breaking existing positional usage, but it deviates from pandas.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org