Yes.. I got it working for dates. I don't want dates though. :) so I figured
out I could just use timeformat %Y.. except that it freaks out when I go
over year 9999. bah...

so... any tips for what way to go for modifying this? I find it hard to
believe that no one before me had this problem.. maybe I should just build a
bunch of rectangles instead of using gant charts?

Thanks again,
Lars

On Tue, Sep 22, 2009 at 6:14 PM, Jim Lemon <jim@bitwrit.com.au> wrote:

> On 09/23/2009 09:24 AM, Lars Skjærven wrote:
>
>> Great. Thanks for a quick reply. That will work I guess. Although, can I
>> use
>> float values instead of dates?
>> so that the "gantt.info" starts and end values are floats instead of
>> dates?
>> or will I have to work around this ?
>>
>>
> Hi Lars,
> Try this for times:
>
> ginfo<-list(
>  labels=c("Jim","Joe","Jim","John","John","Jake","Joe","Jed","Jake"),
>  starts=as.POSIXct(strptime(c("2009-09-23 08:10:00",
>  "2009-09-23 08:25:00","2009-09-23 13:10:00","2009-09-23 08:00:00",
>  "2009-09-23 14:10:00","2009-09-23 09:03:00","2009-09-23 12:33:00",
>  "2009-09-23 09:00:00","2009-09-23 13:17:00"),
>  format="%Y-%m-%d %H:%M:%S")),
>  ends=as.POSIXct(strptime(c("2009-09-23 12:30:00",
>  "2009-09-23 11:47:00","2009-09-23 17:02:00","2009-09-23 13:14:00",
>  "2009-09-23 16:57:00","2009-09-23 12:39:00","2009-09-23 17:21:00",
>  "2009-09-23 17:00:00","2009-09-23 16:19:00"),
>  format="%Y-%m-%d %H:%M:%S")))
> gantt.chart(ginfo,vgrid.format="%H:%M:%S",main="Time at work")
>
> For non-date/time x values, yes, some modification will be needed as the
> function expects time values. Shouldn't be too hard.
>
> Jim
>
>

	[[alternative HTML version deleted]]


