I know this is a common problem, but none of the many other questions I saw fixed this for me. I'm trying to convert numeric timestamps to POSIXct, but no matter what I do, it gives me NA. For example:
as.POSIXct(20090319043255, format="%Y%m%d%H%M%S", origin="1970-01-01")
I've tried just about every variation on the formatting I can think of: inserting spaces, changing the origin format, excluding the origin (which just gives me the "origin must be supplied" error), everything. I'm stumped. Is there something stupid I'm missing?
Before you ask, yes, I've checked the locale. I'm in the United States.
I recommend using the lubridate package. Try running the below code.