@@ -125,9 +125,9 @@ def test_getitem_single_column(self):
125
125
tm .assert_series_equal (result , expected )
126
126
127
127
def test_indices_grouped_by_tuple_with_lambda (self ):
128
- df = pd .DataFrame ({ 'Tuples' : (( x , y )
129
- for x in [0 , 1 ]
130
- for y in np . random . randint ( 3 , 5 , 5 ))} )
128
+ df = pd .DataFrame (
129
+ { "Tuples" : (( x , y ) for x in [0 , 1 ] for y in np . random . randint ( 3 , 5 , 5 ))}
130
+ )
131
131
gb = df .groupby ('Tuples' )
132
132
gb_lambda = df .groupby (lambda x : df .iloc [x , 0 ])
133
133
expected = gb .indices
@@ -785,9 +785,9 @@ def test_get_group_grouped_by_tuple(self):
785
785
tm .assert_frame_equal (result , expected )
786
786
787
787
def test_get_group_grouped_by_tuple_with_lambda (self ):
788
- df = pd .DataFrame ({ 'Tuples' : (( x , y )
789
- for x in [0 , 1 ]
790
- for y in np . random . randint ( 3 , 5 , 5 ))} )
788
+ df = pd .DataFrame (
789
+ { "Tuples" : (( x , y ) for x in [0 , 1 ] for y in np . random . randint ( 3 , 5 , 5 ))}
790
+ )
791
791
gb = df .groupby ('Tuples' )
792
792
gb_lambda = df .groupby (lambda x : df .iloc [x , 0 ])
793
793
expected = gb .get_group (list (gb .groups .keys ())[0 ])
0 commit comments