Skip to content

Commit 2c94312

Browse files
Note __pow__ return type (data-apis#182)
* note pow return type * use dtype * note int to float return type * Update spec/API_specification/dataframe_api/dataframe_object.py Co-authored-by: Keith Kraus <[email protected]> * Update spec/API_specification/dataframe_api/column_object.py Co-authored-by: Keith Kraus <[email protected]> --------- Co-authored-by: Keith Kraus <[email protected]>
1 parent 1bc19ce commit 2c94312

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

spec/API_specification/dataframe_api/column_object.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -363,6 +363,10 @@ def __pow__(self, other: Column | Scalar) -> Column:
363363
"""
364364
Raise this column to the power of `other`.
365365
366+
Integer dtype to the power of non-negative integer dtype is integer dtype.
367+
Integer dtype to the power of float dtype is float dtype.
368+
Float dtype to the power of integer dtype or float dtype is float dtype.
369+
366370
Parameters
367371
----------
368372
other : Column or Scalar

spec/API_specification/dataframe_api/dataframe_object.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -528,6 +528,10 @@ def __pow__(self, other: DataFrame | Scalar) -> DataFrame:
528528
"""
529529
Raise this dataframe to the power of `other`.
530530
531+
Integer dtype to the power of non-negative integer dtype is integer dtype.
532+
Integer dtype to the power of float dtype is float dtype.
533+
Float dtype to the power of integer dtype or float dtype is float dtype.
534+
531535
Parameters
532536
----------
533537
other : DataFrame or Scalar

0 commit comments

Comments
 (0)