开发者

as.Date.numeric requires origin in Linux, not Windows. Fix?

as.Date(10000) works fine in Windows, but on a Linux distribution it errors: 'origin' must be supplied. Somehow the Windows installation has a default origin? I'm trying to build/check a package on Linux that was originally developed on a Windows machine. This package omits the origin parameter all over the place. Is there a quick fix? Perhaps 开发者_高级运维an addition to Rprofile.site?


Load the zoo package. It provides a version of as.Date.numeric with a default origin, e.g.

library(zoo)
as.Date(0)


You must be running an older version of R on your windows machine. as.Date(10000) does not work for me on Windows XP running R-2.13.1.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜