Skip to content
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

Error in the @by example in the documentation #396

Closed
sbacelar opened this issue Jun 4, 2024 · 1 comment · Fixed by #397
Closed

Error in the @by example in the documentation #396

sbacelar opened this issue Jun 4, 2024 · 1 comment · Fixed by #397

Comments

@sbacelar
Copy link

sbacelar commented Jun 4, 2024

The example of @by in the documentation gives an error: ERROR: ArgumentError: column :x in returned data frame is not equal to grouping key :x
Maybe it was better :y_sum = sum(:y)

using DataFrames
using DataFramesMeta

df = DataFrame(x = [1, 1, 2, 2], y = [1, 2, 101, 102]);
@by df :x begin
           :x = sum(:y)
           end
@pdeffebach
Copy link
Collaborator

Good catch!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants