首页 > 解决方案 > 将微秒 Float64Index 转换为 DateTimeIndex Pyton

问题描述

我有价值观:

Float64Index([     0.0, 0.000125,  0.00025, 0.000375,   0.0005, 0.000625,
               0.00075, 0.000875,    0.001, 0.001125,
              ...
               1.99875, 1.998875,    1.999, 1.999125,  1.99925, 1.999375,
                1.9995, 1.999625,  1.99975, 1.999875],
             dtype='float64', name='Date', length=16000)

我想将此索引转换为 DateTime 以研究与此日期对应的时间序列。

我试图用函数转换它: to_datetime但它不起作用。

有人知道该怎么做吗?

非常感谢您的帮助 !

标签: pythonpython-3.xdataframetime-series

解决方案


推荐阅读