[R-SIG-Mac] Formatting of time zone for POSIXct

Don MacQueen macq at llnl.gov
Wed Jan 19 18:41:37 CET 2005


I'm encountering a problem formatting POSIXct objects in R 2.0.1 on OS X.

For reference, on a Solaris system, R 2.0.1 (2004-11-15), formatting 
is correct:

>  Sys.time()
[1] "2005-01-19 09:12:33 PST"
>  format(Sys.time(),'%H:%M %Z')
[1] "09:12 PST"


On Mac OS X, however,

R 2.0.1 Patched 2005-01-19

>  Sys.time()
[1] "2005-01-19 09:18:27 PST"
>  format(Sys.time(),'%H:%M %Z')
[1] "09:18 P"


Or an earlier version of R 2.0.1,  R 2.0.1 2004-11-15
>  Sys.time()
[1] "2005-01-19 09:17:23 PST"
>  format(Sys.time(),'%H:%M %Z')
[1] "09:17 8"


Both Macs are at 10.3.7

The R patched was built from source code with
      configure --enable-R-shlib --with-blas='-framework vecLib' 
--with-lapack --with-aqua >& dhm.config.log

The other R was built from source code with
     configure --enable-R-shlib --with-blas='-framework vecLib' 
--with-lapack --enable-R-framework=no >& dhm.config.log

Changing the TZ environment variable, from the default of "" to 
"US/Pacific" does not help.

Any suggestions?

Thanks
-Don
-- 
--------------------------------------
Don MacQueen
Environmental Protection Department
Lawrence Livermore National Laboratory
Livermore, CA, USA



More information about the R-SIG-Mac mailing list