I'm trying to convert a variable that is imported from CSV into a datetime,I'm trying to use the strptime function but with no joy, can anyone offer any advise?
i have a vector timestamp 07-07-2008-21:03:55 07-07-2008-19:52:55 07-07-2008-19:54:14 07-07-2008-15:24:01 07-07-2008-13:39:17 07-07-2008-13:39:55 timestamp<-strptime(timestamp,"%d-%m-%y-%H:%M:%S") ## then filter on the datetime time<-ifelse(timestamp> "07-08-2008-00:00:00", TRUE, FALSE) -- Michael Pearmain Senior Statistical Analyst Google UK Ltd Belgrave House 76 Buckingham Palace Road London SW1W 9TQ United Kingdom t +44 (0) 2032191684 [EMAIL PROTECTED] If you received this communication by mistake, please don't forward it to anyone else (it may contain confidential or privileged information), please erase all copies of it, including all attachments, and please let the sender know it went to the wrong person. Thanks. [[alternative HTML version deleted]] ______________________________________________ R-help@r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code.