我試圖樞轉下表在[pd.concat的結果(X)],與這行代碼:Python的熊貓 - 混合值類型錯誤樞轉表
df = pd.concat(x).pivot_table(index=["SECURITY", "DATE"], columns="variable", values="value")
DATE SECURITY value variable
0 2017-02-01 EDH8 COMDTY 98.365 PX_LAST
1 2017-02-02 EDH8 COMDTY 98.37 PX_LAST
2 2017-02-03 EDH8 COMDTY 98.36 PX_LAST
3 2017-02-06 EDH8 COMDTY 98.405 PX_LAST
4 2017-02-07 EDH8 COMDTY 98.41 PX_LAST
5 2017-02-08 EDH8 COMDTY 98.435 PX_LAST
6 2017-02-09 EDH8 COMDTY 98.395 PX_LAST
0 2017-02-01 EDH8 COMDTY 1.00804e+06 OPEN_INT
1 2017-02-02 EDH8 COMDTY 1.00999e+06 OPEN_INT
2 2017-02-03 EDH8 COMDTY 1.01918e+06 OPEN_INT
3 2017-02-06 EDH8 COMDTY 1.02386e+06 OPEN_INT
4 2017-02-07 EDH8 COMDTY 1.02461e+06 OPEN_INT
5 2017-02-08 EDH8 COMDTY 1.04626e+06 OPEN_INT
6 2017-02-09 EDH8 COMDTY 1.05029e+06 OPEN_INT
0 2017-02-01 EDH8 COMDTY 2018-03-19 LAST_TRADEABLE_DT
1 2017-02-02 EDH8 COMDTY 2018-03-19 LAST_TRADEABLE_DT
2 2017-02-03 EDH8 COMDTY 2018-03-19 LAST_TRADEABLE_DT
3 2017-02-06 EDH8 COMDTY 2018-03-19 LAST_TRADEABLE_DT
4 2017-02-07 EDH8 COMDTY 2018-03-19 LAST_TRADEABLE_DT
5 2017-02-08 EDH8 COMDTY 2018-03-19 LAST_TRADEABLE_DT
6 2017-02-09 EDH8 COMDTY 2018-03-19 LAST_TRADEABLE_DT
這導致儘管如下錯誤:DataError:沒有數字類型進行聚合。有任何想法嗎?謝謝!