[R] is.Date ?!!!

Duncan Murdoch murdoch at stats.uwo.ca
Wed Jul 20 16:57:52 CEST 2005


On 7/20/2005 10:41 AM, Omar Lakkis wrote:
> Is there a way to test if a variable is a date?

Yes, but there are several different things people might call dates. 
Which do you mean?

For example,

 > today <- Sys.Date()
 > today
[1] "2005-07-20"
 > inherits(today, "Date")
[1] TRUE

Duncan Murdoch




More information about the R-help mailing list