guopengfa
发布于 2020-08-11 / 729 阅读 / 0 评论 / 0 点赞

pandas,DateRange保留格式转换成list

import re
import pandas as pd
print(pd.date_range("2020-01-01","2020-02-01"))
dara = pd.DataFrame({"A":pd.date_range("2020-01-01","2020-02-01")})["A"].astype(str).tolist()
dara

评论