Skip to content

Instantly share code, notes, and snippets.

@abelsonlive
Created May 17, 2012 06:50
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save abelsonlive/2717070 to your computer and use it in GitHub Desktop.
Save abelsonlive/2717070 to your computer and use it in GitHub Desktop.
unix time to date object conversion
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")
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