[R] Date issues
    David Winsemius 
    dwinsemius at comcast.net
       
    Sat Sep 18 17:36:44 CEST 2010
    
    
  
On Sep 18, 2010, at 11:25 AM, Santosh Srinivas wrote:
> Strangely this is not working ... what am I doing wrong here?
>
>> tDate <- FnO_Data$Date[1]
>> tDate
> [1] 20090101
>> as.Date(c(tDate),format="%Y%m%d")
> [1] NA
?sasDate
as.Date does not take numeric arguments. Try:
 > as.Date(as.character(tDate), format="%Y%M%d")
[1] "2009-09-01"
-- 
David Winsemius, MD
West Hartford, CT
    
    
More information about the R-help
mailing list