@@ -2791,7 +2791,7 @@ class TestDataFrameGroupByPlots(TestPlotBase):
27912791 def test_boxplot (self ):
27922792 grouped = self .hist_df .groupby (by = 'gender' )
27932793 axes = _check_plot_works (grouped .boxplot , return_type = 'axes' )
2794- self ._check_axes_shape (axes .values (), axes_num = 2 , layout = (1 , 2 ))
2794+ self ._check_axes_shape (list ( axes .values () ), axes_num = 2 , layout = (1 , 2 ))
27952795
27962796 axes = _check_plot_works (grouped .boxplot , subplots = False ,
27972797 return_type = 'axes' )
@@ -2803,15 +2803,15 @@ def test_boxplot(self):
28032803
28042804 grouped = df .groupby (level = 1 )
28052805 axes = _check_plot_works (grouped .boxplot , return_type = 'axes' )
2806- self ._check_axes_shape (axes .values (), axes_num = 10 , layout = (4 , 3 ))
2806+ self ._check_axes_shape (list ( axes .values () ), axes_num = 10 , layout = (4 , 3 ))
28072807
28082808 axes = _check_plot_works (grouped .boxplot , subplots = False ,
28092809 return_type = 'axes' )
28102810 self ._check_axes_shape (axes , axes_num = 1 , layout = (1 , 1 ))
28112811
28122812 grouped = df .unstack (level = 1 ).groupby (level = 0 , axis = 1 )
28132813 axes = _check_plot_works (grouped .boxplot , return_type = 'axes' )
2814- self ._check_axes_shape (axes .values (), axes_num = 3 , layout = (2 , 2 ))
2814+ self ._check_axes_shape (list ( axes .values () ), axes_num = 3 , layout = (2 , 2 ))
28152815
28162816 axes = _check_plot_works (grouped .boxplot , subplots = False ,
28172817 return_type = 'axes' )
@@ -2988,14 +2988,14 @@ def test_grouped_box_multiple_axes(self):
29882988 fig , axes = self .plt .subplots (2 , 3 )
29892989 returned = df .boxplot (column = ['height' , 'weight' , 'category' ], by = 'gender' ,
29902990 return_type = 'axes' , ax = axes [0 ])
2991- returned = np .array (returned .values ())
2991+ returned = np .array (list ( returned .values () ))
29922992 self ._check_axes_shape (returned , axes_num = 3 , layout = (1 , 3 ))
29932993 self .assert_numpy_array_equal (returned , axes [0 ])
29942994 self .assertIs (returned [0 ].figure , fig )
29952995 # draw on second row
29962996 returned = df .groupby ('classroom' ).boxplot (column = ['height' , 'weight' , 'category' ],
29972997 return_type = 'axes' , ax = axes [1 ])
2998- returned = np .array (returned .values ())
2998+ returned = np .array (list ( returned .values () ))
29992999 self ._check_axes_shape (returned , axes_num = 3 , layout = (1 , 3 ))
30003000 self .assert_numpy_array_equal (returned , axes [1 ])
30013001 self .assertIs (returned [0 ].figure , fig )
0 commit comments