Re: [R] how to apply a date format for data frame

2009-08-25 Thread Don MacQueen
Assuming your starts and ends are the number of days since some starting point (day 0), then following this example might do what you want: x <- 45678 class(x) <- 'Date' x [1] "2095-01-23" You will have to study the documentation to find out if your starting point is the same as R's, an

Re: [R] how to apply a date format for data frame

2009-08-25 Thread Stefan Grosse
On Mon, 24 Aug 2009 23:42:11 -0700 (PDT) rajclinasia wrote: R> labels starts ends priorities R> 1 firsttask 37987 38049 1 It is easier with the other data.frame you had with: labels starts ends 1 first task 1-Jan-04 3-Mar-04 and as.Date see ?as.Date e.g. as.Dat

Re: [R] how to apply a date format for data frame

2009-08-25 Thread Uwe Ligges
rajclinasia wrote: Hi Everyone, i have a data frame like this labels starts ends priorities 1 firsttask 37987 38049 1 2 secondtask 38019 38112 2 3 thirdtask 38049 38144 3 4 fourthtask 38081 38207 4 5 fifthtask 38112 38239 5 now i wa

[R] how to apply a date format for data frame

2009-08-24 Thread rajclinasia
Hi Everyone, i have a data frame like this labels starts ends priorities 1 firsttask 37987 38049 1 2 secondtask 38019 38112 2 3 thirdtask 38049 38144 3 4 fourthtask 38081 38207 4 5 fifthtask 38112 38239 5 now i want to apply a date for