1

I want to plot a graph in excel which has x-axis values as times(just of one day, this will be plotted everyday) and y-axis values as different applications. Suppose an application A runs jobs from 1:00 pm to 2:00 pm and then from 4:00 pm to 6:00 pm. Is there a way I can plot these time durations for each application?

I am visualizing a graph where an application has a colored bar next to it for the time period 1pm to 2pm and then it is blank until 4pm where another colored bar appears till 6pm.

Is this possible? I have the start and end times of jobs for each application. Differentiating between jobs is not important. I just need to know when the application is running and when it is idle.

Any help would be appreciated! Thanks

1 Answers1

0

A little example:

SO24459314 example

The data is a label in ColumnA (for the y-axis) and 'readings' (here in B1:G1). The 'readings' are the length of the static intervals (in hours). 0 because the day has changed, then 13 because nothing happens until 1p.m., 1 because busy 1-2 p.m. - and so on.

If charted with Insert Stacked Bar the default will be to colour fill each range (interval) with a different colour. For the image, the colour for alternate 'series' has been set to match the background and one of the remaining set to match the other.

I admit changing the fill manually could get tedious if required daily for many apps but there is always VBA! And with a small fudge you may be able to 'recycle' (ie use the chart as a template and just overwrite "yesterday's" data.

pnuts
  • 58,317
  • 11
  • 87
  • 139