Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何从 facebook api pull 重新编码时间戳矢量,该 api pull 是一个类似于以下时间/日期变量的因子?
[[1] 2012-10-19T19:52:43+0000
我尝试了以下方法,但我只得到了 NA:
strptime(as.character(time), "%Y-%b-%dT%H:%M:%S+0000")
你的格式不对。%b应该%m是。
%b
%m
> strptime("2012-10-19T19:52:43+0000", "%Y-%m-%dT%H:%M:%S+0000") [1] "2012-10-19 19:52:43"