rodrigorgs
rodrigorgs

Reputation: 875

as.POSIXct rejects +1300 timezone

I'm using as.POSIXct to parse times with timezones, like this:

as.POSIXct("2009-01-05 14:19 +1200", format="%Y-%m-%d %H:%M %z")

However, if the string includes the timezone information +1300, the function returns NA:

> as.POSIXct("2009-01-05 14:19 +1300", format="%Y-%m-%d %H:%M %z")
[1] NA

Aparently +1300 is a valid timezone (NZDT – New Zealand Daylight Time). How to convince R to parse it?

Upvotes: 5

Views: 374

Answers (1)

tonytonov
tonytonov

Reputation: 25608

This was a bug in 3.0.2 release, which was fixed in R-3.1.0 Patched build.

Upvotes: 1

Related Questions