Skip to content
Prev 43709 / 398503 Next

Date Time Conversion problems...

On Wed, Feb 04, 2004 at 08:31:56AM -0600, Shawn Way wrote:
The '9 rows' gives it aways -- it works with an explicit time object cast:

data2$Date <- as.POSIXct(strptime(as.character(data2$Date),format="%m/%d/%Y"))
start <- as.POSIXct(strptime(c("1/01/2003"),format="%m/%d/%Y"))
end <- as.POSIXct(strptime(c("12/31/2003"),format="%m/%d/%Y"))
It works.  A more formal way is in the subsetting and range functions for
the its package.

Dirk