Dear R users, I want to make a barplot with bars that can be non-continuous. An example will be the presence and absence of some events over time, e.g. a bunch of people that are either in the office or not in the office, for some period of time. I want to visualize this in a bar plot like this: Person 1: ********* ******** ******* Person 2: ********* ***** ********** Person 3: ************** *********** Any tips on how this can be done? Thanks, Lars [[alternative HTML version deleted]]
On 09/23/2009 07:14 AM, Lars Skj?rven wrote:> Dear R users, > I want to make a barplot with bars that can be non-continuous. An example > will be the presence and absence of some events over time, e.g. a bunch of > people that are either in the office or not in the office, for some period > of time. I want to visualize this in a bar plot like this: > > Person 1: ********* ******** ******* > Person 2: ********* ***** ********** > Person 3: ************** *********** > > Any tips on how this can be done? > >Hi Lars, This looks a bit like a Gantt chart. There are functions to produce these in the plotrix and plan packages. Jim
I think you might be looking for a Gantt chart: http://finzi.psych.upenn.edu/R/library/plotrix/html/gantt.chart.html On Sep 22, 2009, at 5:14 PM, Lars Skj?rven wrote:> Dear R users, > I want to make a barplot with bars that can be non-continuous. An > example > will be the presence and absence of some events over time, e.g. a > bunch of > people that are either in the office or not in the office, for some > period > of time. I want to visualize this in a bar plot like this: > > Person 1: ********* ******** ******* > Person 2: ********* ***** ********** > Person 3: ************** *********** > > Any tips on how this can be done?-- David Winsemius, MD Heritage Laboratories West Hartford, CT