Re: [Rd] as.Date: conversion pb from POSIXct (PR#9386)

From: Gabor Grothendieck <ggrothendieck_at_gmail.com>
Date: Mon 27 Nov 2006 - 13:21:03 GMT

as.Date is converting your object with respect to GMT time zone and in that time zone your POSIXct date is the day before. See ?as.Date and also suggest you read R News 4/1 help desk article.

On 11/27/06, xiao.gang.fan1@free.fr <xiao.gang.fan1@free.fr> wrote:
> Full_Name: Xiao Gang FAN
> Version: 2.4.0
> OS: Windows
> Submission from: (NULL) (159.50.101.9)
>
>
> > library(chron)
> > as.Date(as.POSIXct(strptime("1994-01-24","%Y-%m-%d")))

> [1] "1994-01-23"
>
> ______________________________________________
> R-devel@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel
>



R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel Received on Tue Nov 28 13:47:38 2006

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.1.8, at Tue 28 Nov 2006 - 04:30:51 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-devel. Please read the posting guide before posting to the list.