Re: [R] Error as.Date on Invalid Dates

2009-01-24 Thread Peter Dalgaard
Marie Sivertsen wrote: I am relatively new to R, so maybe I am miss something, but I now tried the as.Date now and have problems understanding how it works (or don't work as it seem). Brian D Ripley wrote: On Thu, 22 Jan 2009, Terry Therneau wrote: One idea is to use the as.date function,

Re: [R] Error as.Date on Invalid Dates

2009-01-22 Thread Terry Therneau
-begin included message However, as.Date encounters an error when the string does not represent an actual date. eg: date1 - 2009-02-29 # Note: 2009 not a leap year as.Date(date1) Error in fromchar(x) : character string is not in a standard unambiguous format As I have many

Re: [R] Error as.Date on Invalid Dates

2009-01-22 Thread Brian D Ripley
On Thu, 22 Jan 2009, Terry Therneau wrote: -begin included message However, as.Date encounters an error when the string does not represent an actual date. eg: date1 - 2009-02-29 # Note: 2009 not a leap year as.Date(date1) Error in fromchar(x) : character string is not in a

Re: [R] Error as.Date on Invalid Dates

2009-01-22 Thread Marie Sivertsen
I am relatively new to R, so maybe I am miss something, but I now tried the as.Date now and have problems understanding how it works (or don't work as it seem). Brian D Ripley wrote: On Thu, 22 Jan 2009, Terry Therneau wrote: One idea is to use the as.date function, for the older (and less

[R] Error as.Date on Invalid Dates

2009-01-21 Thread Brigid Mooney
Hi All, I have an script in R which accepts user inputs for certain parameters, particularly dates, which the user inputs as character strings. eg: date1 - 2009-01-21 The script later parses the input via the as.Date function: as.Date(date1) However, as.Date encounters an error when the

Re: [R] Error as.Date on Invalid Dates

2009-01-21 Thread jim holtman
?try On Wed, Jan 21, 2009 at 10:55 AM, Brigid Mooney bkmoo...@gmail.com wrote: Hi All, I have an script in R which accepts user inputs for certain parameters, particularly dates, which the user inputs as character strings. eg: date1 - 2009-01-21 The script later parses the input via the