0

我不知道为什么我会收到密钥错误:'Tested On'

msft = pd.read_csv("C:\\Users\\gomat\\Desktop\\Py TR\\week_06.csv")
msft['Tested On'] = pd.to_datetime(msft['Tested On'],dayfirst =True)
msft = msft[msft['Tested On'].dt.floor('d') == '2018-06-02']

样本数据:

| Plan | Run | Status | Tested On | |------|----------|----------------|------------| | P0 | Agent | Passed | 2018-08-11 | | | Customer | Failed | 2018-08-01 | | P1 | A | Passed | 2018-08-02 | | | B | Untested | 2018-08-11 | | P2 | C | Not Applicable | 2018-08-05 |

4

0 回答 0