Created
May 17, 2012 06:50
-
-
Save abelsonlive/2717070 to your computer and use it in GitHub Desktop.
unix time to date object conversion
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
data$date <- as.POSIXlt(data$unix_time, origin="1970-01-01", tz="America/New_York") | |
data$date <- as.Date(data$date, format="%Y-%m-%d") |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
data$date <- as.POSIXlt(data$unix_time, origin="1970-01-01", tz="America/New_York") | |
data$date <- as.Date(data$date, format="%Y-%m-%d") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment