You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@beam.apache.org by GitBox <gi...@apache.org> on 2021/06/14 07:28:08 UTC

[GitHub] [beam] TheNeuralBit commented on a change in pull request #14929: [BEAM-9547] Add support for `Series.value_counts()`, add back the ability to group by a Series

TheNeuralBit commented on a change in pull request #14929:
URL: https://github.com/apache/beam/pull/14929#discussion_r650134370



##########
File path: sdks/python/apache_beam/dataframe/frames_test.py
##########
@@ -971,6 +974,44 @@ def test_groupby_sum_min_count(self):
 
     self._run_test(lambda df: df.groupby('group').sum(min_count=2), df)
 
+  @parameterized.expand(frames.ALL_AGGREGATIONS)
+  def test_dataframe_groupby_series(self, agg_type):
+    if agg_type == 'describe' and PD_VERSION < (1, 2):
+      self.skipTest(
+          "BEAM-12366: proxy generation of DataFrameGroupBy.describe "
+          "fails in pandas < 1.2")
+    self._run_test(
+        lambda df: df[df.foo > 40].groupby(df.group).agg(agg_type), GROUPBY_DF)

Review comment:
       Good point, done.




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org