You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add support for DataFrame sum operation with tests (#1148)
* Add support for DataFrame `sum` operation with tests
Introduced the `sum` operation for DataFrames, supporting numerical columns aggregation. Updated relevant tests and added new test cases to verify functionality. Included schema modifications for handling numerical column operations.
* Make aggregator-related classes and functions public
Converted various internal classes, interfaces, and functions related to aggregation into public entities. This change expands their visibility, enabling external usage and facilitating integration with other modules or libraries.
* Enhance type conversions between `KType` and `ConeKotlinType` to ensure compatibility and correctness in sum calculations.
* Update plugins/kotlin-dataframe/testData/box/sum.kt
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Refactor type conversion and column handling logic
* Fixed review
* Fixed conflict
* Fix linting
---------
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copy file name to clipboardExpand all lines: core/src/main/kotlin/org/jetbrains/kotlinx/dataframe/impl/aggregation/aggregators/AggregatorAggregationHandler.kt
+5-6
Original file line number
Diff line number
Diff line change
@@ -11,8 +11,7 @@ import kotlin.reflect.KType
11
11
* It also provides information on which return type will be given, as [KType], given a [value type][ValueType].
12
12
* It can also provide the index of the result in the input values if it is a selecting aggregator.
Copy file name to clipboardExpand all lines: core/src/main/kotlin/org/jetbrains/kotlinx/dataframe/impl/aggregation/aggregators/AggregatorInputHandler.kt
+4-4
Original file line number
Diff line number
Diff line change
@@ -8,13 +8,13 @@ import kotlin.reflect.KType
8
8
* It can also calculate a specific [value type][ValueType] from the input values or input types
Copy file name to clipboardExpand all lines: core/src/main/kotlin/org/jetbrains/kotlinx/dataframe/impl/aggregation/aggregators/AggregatorMultipleColumnsHandler.kt
+3-3
Original file line number
Diff line number
Diff line change
@@ -10,14 +10,14 @@ import kotlin.reflect.KType
10
10
* [AggregatorAggregationHandler].
11
11
* It can also calculate the return type of the aggregation given all input column types.
Copy file name to clipboardExpand all lines: core/src/main/kotlin/org/jetbrains/kotlinx/dataframe/impl/aggregation/aggregators/AggregatorOptionSwitch.kt
Copy file name to clipboardExpand all lines: core/src/main/kotlin/org/jetbrains/kotlinx/dataframe/impl/aggregation/aggregators/multipleColumnsHandlers/TwoStepMultipleColumnsHandler.kt
+1-1
Original file line number
Diff line number
Diff line change
@@ -31,7 +31,7 @@ import kotlin.reflect.KType
31
31
* If not supplied, the handler of the first step is reused.
0 commit comments