我正在尝试将包含当前存储为数字的日期的表列(aifstime_local)转换为日期时间。见下表。
aifstime_utc aifstime_local lat lon apparent_t cloud cloud_base_m
1 20190224230000 20190225083000 -12.6099 131.0474 31.8 - NULL
2 20190224223000 20190225080000 -12.6099 131.0474 30.9 - NULL
3 20190224220000 20190225073000 -12.6099 131.0474 30.1 - NULL
4 20190224213000 20190225070000 -12.6099 131.0474 30.2 - NULL
5 20190224210000 20190225063000 -12.6099 131.0474 30.2 - NULL
6 20190224203000 20190225060000 -12.6099 131.0474 29.4 - NULL
我已经尝试使用任何时间包中的任何时间功能
library(anytime)
MyData$aifstime_local <- anytime(MyData$aifstime_local)
但是,这只返回日期,而不是我需要的日期时间,见下文
aifstime_utc aifstime_local lat lon apparent_t cloud cloud_base_m
1 20190224230000 2019-02-25 -12.6099 131.0474 31.8 - NULL
2 20190224223000 2019-02-25 -12.6099 131.0474 30.9 - NULL
3 20190224220000 2019-02-25 -12.6099 131.0474 30.1 - NULL
4 20190224213000 2019-02-25 -12.6099 131.0474 30.2 - NULL
5 20190224210000 2019-02-25 -12.6099 131.0474 30.2 - NULL
6 20190224203000 2019-02-25 -12.6099 131.0474 29.4 - NULL
是否有任何功能可以帮助完成这项任务?