Skip to content

make skip_nulls keyword-only #161

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 3, 2023
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
20 changes: 10 additions & 10 deletions spec/API_specification/dataframe_api/column_object.py
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ def __invert__(self) -> Column:
If any of the Column's columns is not boolean.
"""

def any(self, skip_nulls: bool = True) -> bool:
def any(self, *, skip_nulls: bool = True) -> bool:
"""
Reduction returns a bool.

Expand All @@ -280,7 +280,7 @@ def any(self, skip_nulls: bool = True) -> bool:
If column is not boolean.
"""

def all(self, skip_nulls: bool = True) -> bool:
def all(self, *, skip_nulls: bool = True) -> bool:
"""
Reduction returns a bool.

Expand All @@ -290,56 +290,56 @@ def all(self, skip_nulls: bool = True) -> bool:
If column is not boolean.
"""

def min(self, skip_nulls: bool = True) -> dtype:
def min(self, *, skip_nulls: bool = True) -> dtype:
"""
Reduction returns a scalar. Any data type that supports comparisons
must be supported. The returned value has the same dtype as the column.
"""

def max(self, skip_nulls: bool = True) -> dtype:
def max(self, *, skip_nulls: bool = True) -> dtype:
"""
Reduction returns a scalar. Any data type that supports comparisons
must be supported. The returned value has the same dtype as the column.
"""

def sum(self, skip_nulls: bool = True) -> dtype:
def sum(self, *, skip_nulls: bool = True) -> dtype:
"""
Reduction returns a scalar. Must be supported for numerical and
datetime data types. The returned value has the same dtype as the
column.
"""

def prod(self, skip_nulls: bool = True) -> dtype:
def prod(self, *, skip_nulls: bool = True) -> dtype:
"""
Reduction returns a scalar. Must be supported for numerical data types.
The returned value has the same dtype as the column.
"""

def median(self, skip_nulls: bool = True) -> dtype:
def median(self, *, skip_nulls: bool = True) -> dtype:
"""
Reduction returns a scalar. Must be supported for numerical and
datetime data types. Returns a float for numerical data types, and
datetime (with the appropriate timedelta format string) for datetime
dtypes.
"""

def mean(self, skip_nulls: bool = True) -> dtype:
def mean(self, *, skip_nulls: bool = True) -> dtype:
"""
Reduction returns a scalar. Must be supported for numerical and
datetime data types. Returns a float for numerical data types, and
datetime (with the appropriate timedelta format string) for datetime
dtypes.
"""

def std(self, skip_nulls: bool = True) -> dtype:
def std(self, *, skip_nulls: bool = True) -> dtype:
"""
Reduction returns a scalar. Must be supported for numerical and
datetime data types. Returns a float for numerical data types, and
datetime (with the appropriate timedelta format string) for datetime
dtypes.
"""

def var(self, skip_nulls: bool = True) -> dtype:
def var(self, *, skip_nulls: bool = True) -> dtype:
"""
Reduction returns a scalar. Must be supported for numerical and
datetime data types. Returns a float for numerical data types, and
Expand Down
24 changes: 12 additions & 12 deletions spec/API_specification/dataframe_api/dataframe_object.py
Original file line number Diff line number Diff line change
Expand Up @@ -543,7 +543,7 @@ def __iter__(self) -> NoReturn:
"""
raise NotImplementedError("'__iter__' is intentionally not implemented.")

def any(self, skip_nulls: bool = True) -> DataFrame:
def any(self, *, skip_nulls: bool = True) -> DataFrame:
"""
Reduction returns a 1-row DataFrame.

Expand All @@ -554,7 +554,7 @@ def any(self, skip_nulls: bool = True) -> DataFrame:
"""
...

def all(self, skip_nulls: bool = True) -> DataFrame:
def all(self, *, skip_nulls: bool = True) -> DataFrame:
"""
Reduction returns a 1-row DataFrame.

Expand All @@ -565,7 +565,7 @@ def all(self, skip_nulls: bool = True) -> DataFrame:
"""
...

def any_rowwise(self, skip_nulls: bool = True) -> Column:
def any_rowwise(self, *, skip_nulls: bool = True) -> Column:
"""
Reduction returns a Column.

Expand All @@ -579,7 +579,7 @@ def any_rowwise(self, skip_nulls: bool = True) -> Column:
"""
...

def all_rowwise(self, skip_nulls: bool = True) -> Column:
def all_rowwise(self, *, skip_nulls: bool = True) -> Column:
"""
Reduction returns a Column.

Expand All @@ -593,49 +593,49 @@ def all_rowwise(self, skip_nulls: bool = True) -> Column:
"""
...

def min(self, skip_nulls: bool = True) -> DataFrame:
def min(self, *, skip_nulls: bool = True) -> DataFrame:
"""
Reduction returns a 1-row DataFrame.
"""
...

def max(self, skip_nulls: bool = True) -> DataFrame:
def max(self, *, skip_nulls: bool = True) -> DataFrame:
"""
Reduction returns a 1-row DataFrame.
"""
...

def sum(self, skip_nulls: bool = True) -> DataFrame:
def sum(self, *, skip_nulls: bool = True) -> DataFrame:
"""
Reduction returns a 1-row DataFrame.
"""
...

def prod(self, skip_nulls: bool = True) -> DataFrame:
def prod(self, *, skip_nulls: bool = True) -> DataFrame:
"""
Reduction returns a 1-row DataFrame.
"""
...

def median(self, skip_nulls: bool = True) -> DataFrame:
def median(self, *, skip_nulls: bool = True) -> DataFrame:
"""
Reduction returns a 1-row DataFrame.
"""
...

def mean(self, skip_nulls: bool = True) -> DataFrame:
def mean(self, *, skip_nulls: bool = True) -> DataFrame:
"""
Reduction returns a 1-row DataFrame.
"""
...

def std(self, skip_nulls: bool = True) -> DataFrame:
def std(self, *, skip_nulls: bool = True) -> DataFrame:
"""
Reduction returns a 1-row DataFrame.
"""
...

def var(self, skip_nulls: bool = True) -> DataFrame:
def var(self, *, skip_nulls: bool = True) -> DataFrame:
"""
Reduction returns a 1-row DataFrame.
"""
Expand Down
20 changes: 10 additions & 10 deletions spec/API_specification/dataframe_api/groupby_object.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,34 +17,34 @@ class GroupBy:
**Methods**

"""
def any(self, skip_nulls: bool = True) -> "DataFrame":
def any(self, *, skip_nulls: bool = True) -> "DataFrame":
...

def all(self, skip_nulls: bool = True) -> "DataFrame":
def all(self, *, skip_nulls: bool = True) -> "DataFrame":
...

def min(self, skip_nulls: bool = True) -> "DataFrame":
def min(self, *, skip_nulls: bool = True) -> "DataFrame":
...

def max(self, skip_nulls: bool = True) -> "DataFrame":
def max(self, *, skip_nulls: bool = True) -> "DataFrame":
...

def sum(self, skip_nulls: bool = True) -> "DataFrame":
def sum(self, *, skip_nulls: bool = True) -> "DataFrame":
...

def prod(self, skip_nulls: bool = True) -> "DataFrame":
def prod(self, *, skip_nulls: bool = True) -> "DataFrame":
...

def median(self, skip_nulls: bool = True) -> "DataFrame":
def median(self, *, skip_nulls: bool = True) -> "DataFrame":
...

def mean(self, skip_nulls: bool = True) -> "DataFrame":
def mean(self, *, skip_nulls: bool = True) -> "DataFrame":
...

def std(self, skip_nulls: bool = True) -> "DataFrame":
def std(self, *, skip_nulls: bool = True) -> "DataFrame":
...

def var(self, skip_nulls: bool = True) -> "DataFrame":
def var(self, *, skip_nulls: bool = True) -> "DataFrame":
...

def size(self) -> "DataFrame":
Expand Down