Try this:
format(dt, '%Y-%m-%d'), if you want Date class:
as.Date(format(dt, '%Y-%m-%d'))
On Mon, Sep 13, 2010 at 2:24 PM, Andrew Yee
wrote:
Thanks David, now I wonder how you can have as.Date() render the
date using
local time rather than UTC.
Andrew
On Mon, Sep 13, 2010 at 12:08 PM
Henrique, thanks for your suggestion. For my applications, character would
have been sufficient, so your suggestion of using format() works fine too.
Perhaps I should submit a feature request for as.Date() to let you specify
local time.
Thanks,
Andrew
On Mon, Sep 13, 2010 at 2:06 PM, Henrique D
On Sep 13, 2010, at 1:24 PM, Andrew Yee wrote:
> Thanks David, now I wonder how you can have as.Date() render the
> date using local time rather than UTC.
>
Since we are both in the EDT TZ at the moment, our times are UTC-4
(hours = 60*60 seconds)
> dt <- as.POSIXct("2010-08-22 23:14:52")
Thanks David, now I wonder how you can have as.Date() render the date using
local time rather than UTC.
Andrew
On Mon, Sep 13, 2010 at 12:08 PM, David Winsemius wrote:
>
> On Sep 13, 2010, at 11:56 AM, Andrew Yee wrote:
>
> I'm trying to understand why as.Date() is converting a the modified dat
On Sep 13, 2010, at 11:56 AM, Andrew Yee wrote:
I'm trying to understand why as.Date() is converting a the modified
date of
a file from August 22 to August 23.
foo <- file.info(file.to.process)
str(foo)
'data.frame': 1 obs. of 10 variables:
$ size : num 5.37e+09
$ isdir : logi FALSE
$
I'm trying to understand why as.Date() is converting a the modified date of
a file from August 22 to August 23.
> foo <- file.info(file.to.process)
> str(foo)
'data.frame': 1 obs. of 10 variables:
$ size : num 5.37e+09
$ isdir : logi FALSE
$ mode :Class 'octmode' int 436
$ mtime : POSIX
6 matches
Mail list logo