-
-
Notifications
You must be signed in to change notification settings - Fork 19.3k
Closed
Labels
Needs TriageIssue that has not been reviewed by a pandas team memberIssue that has not been reviewed by a pandas team memberUsage Question
Description
Research
-
I have searched the [pandas] tag on StackOverflow for similar questions.
-
I have asked my usage related question on StackOverflow.
Link to question on StackOverflow
https://stackoverflow.com/questions/78845935/qst-how-to-use-numba-for-group-by-sum
Question about pandas
import numba
@numba.njit
def sum_func(index, values):
return pd.Series(np.sum(values), index=index)
df_long_control[['user_id', 'reward_type', 'reward']].groupby(['user_id', 'reward_type'], as_index=False).apply(sum_func, engine='numba')
I'm trying to group by user_id and reward_type and apply sum function using numba, but got an error
TypeError: sum_func() got an unexpected keyword argument 'engine'
Metadata
Metadata
Assignees
Labels
Needs TriageIssue that has not been reviewed by a pandas team memberIssue that has not been reviewed by a pandas team memberUsage Question