【发布时间】:2014-07-10 00:33:52
【问题描述】:
我在使用 lubridate 的 pretty_dates 函数时遇到问题。在某些情况下它会失败:
library(lubridate)
datetimes <- structure(c(1391640346, 1393856900), class = c("POSIXct", "POSIXt"), tzone = "GMT")
pretty_dates(datetimes, 10)
(我通常不会像这样构造日期时间,这正是dput 给我的。)
这失败并显示错误消息:
Error in seq.POSIXt(start, end, paste(binlength, binunits)) : 'to' must be of length 1
我在这里做错了吗?
我正在使用lubridate_1.3.3,来自 CRAN 的最新版本。
【问题讨论】: