[R] Bug in as.POSIXct regarding AM/PM

Ted Zeng (曾振兴) zengzhenxing at gmail.com
Fri Oct 8 11:54:12 CEST 2010


Dear All,

I encounted in a problem with as.POSIXct() function.

> as.POSIXct("2009/03/26 01:00:00 AM" , format="%Y/%m/%d %I:%M:%S %p") 
[1] NA
> as.POSIXct("2009/03/26 02:00:00 PM" , format="%Y/%m/%d %I:%M:%S %p")
[1] NA

I have tried this in the R version 2.11.1,  R version 2.10.1  and R version
2.9.2 . They all does not work. The operation system is win7. 

Thanks

Ted
-- 
View this message in context: http://r.789695.n4.nabble.com/Bug-in-as-POSIXct-regarding-AM-PM-tp2968076p2968076.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list