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
Right now, we offer the count_cat reduction operator, which effectively does the count reduction separately per category. Most of the other reduction operators would also be meaningful to do categorically, and it would be a pain to implement a categorical version of each one as it is needed.
Instead, we should be able to implement a general-purpose categorical operator, similar to the summary operator, which takes a scalar reduction operator and applies it per category. @jcrist suggests a syntax like by('category_column', mean('some_other_column')), which seems clear to me as well. I think we should do this as soon as we need to apply any operator other than count to categories, since making a general version is probably not much more difficult than copying count_cat and changing the counting bits.
The text was updated successfully, but these errors were encountered:
Right now, we offer the
count_cat
reduction operator, which effectively does thecount
reduction separately per category. Most of the other reduction operators would also be meaningful to do categorically, and it would be a pain to implement a categorical version of each one as it is needed.Instead, we should be able to implement a general-purpose categorical operator, similar to the
summary
operator, which takes a scalar reduction operator and applies it per category. @jcrist suggests a syntax likeby('category_column', mean('some_other_column'))
, which seems clear to me as well. I think we should do this as soon as we need to apply any operator other thancount
to categories, since making a general version is probably not much more difficult than copying count_cat and changing the counting bits.The text was updated successfully, but these errors were encountered: