I have a set of data from across the US that I am trying to convert into local time for each "subject". I have UTC timestamps on each event and have converted those into POSIXct format, but every time I try to include a vector of tz = DS$Factor or tz = as.character(DS$Factor) in any of the POSIXct/POSIXlt functions (including format() and strftime()) I get an error that says:
Error in as.POSIXlt.POSIXct(x, tz = tz) : invalid 'tz' value
If I just enter tz = 'US/Eastern' it works fine, but of course not all of my values are from that time zone.
How do I get the time stamps into local time for each "subject"?
The DS$Factor has 5 values: US/Arizona US/Central US/Eastern US/Mountain US/Pacific
Thanks, Shorthand