回答編集履歴

2

コード修正

2018/07/01 07:12

投稿

can110
can110

スコア38262

test CHANGED
@@ -46,6 +46,8 @@
46
46
 
47
47
  print(gr.describe())
48
48
 
49
- print(gr.mean().loc[:,('A','B','C')])
49
+ cols = ('A','B','C')
50
+
51
+ print(gr.mean().loc[:,cols])
50
52
 
51
53
  ```

1

コード追加

2018/07/01 07:12

投稿

can110
can110

スコア38262

test CHANGED
@@ -38,4 +38,14 @@
38
38
 
39
39
  print (df)
40
40
 
41
+
42
+
43
+ # 集計
44
+
45
+ gr = df.groupby('曜日-時間')
46
+
47
+ print(gr.describe())
48
+
49
+ print(gr.mean().loc[:,('A','B','C')])
50
+
41
51
  ```