Where used to see Gantt charts for illustrating project timelines, but what if I wanted to visualize passed timed events? Here's how.
I came across the need to easily visualize the time window for my database backups, and thought that displaying them through a Gantt chart would five a nice and easy way to illustrate them.
However, being a lazy data scripting guy, I wasn't found of going through all the trouble of drawing the whole thing, there should be a way of clicking a few buttons and make magic, and after a few tips & trick out of the internet, and a lot of trial & error, I finally made it happen...and here is how.
Let us start by assuming that we've already imported the data to excel (check this
article on how to get to this point ;))
INSERT a 2-D Stacked Bar chart on your excel sheet
- With the new chart object active, one needs to select the Data:
In the "Select Data Source" window, Add Legend Entries (Series) the backup_start_date and the Duration. Notice that the first field is the name of the series, and the second is the values. This Values filed has a default value of ={1}, make sure you delete it so you wont end up with something like ={1}+Sheet1!$B$2...
Edit the "Horizontal (Category) Axis Labels" to be the database_name
![ee5.PNG]()
Ending up with the following selected data source:
![ee6.PNG]()
And the corresponding stacked bar chart
![ee7.PNG]()
Are we there yet? not yet, almost.
Now for some cosmetic magic:
Select the Series "backup_start_date", either directly on the chart, or the "FORMAT" menu under "CHART TOOLS" - "Format Selection"
![ee8.PNG]()
![ee9.PNG]()
And choose "No Fill" on the "Format Data Series"
Finally, to adjust the start of the graph, copy the lowest start date to another cell (9-11-15 3:58) and format it as Number (42258.165787037) and take note.
Select the "Horizontal (Value) Axis", again, either directly clicking it on the chart, or through the "FORMAT" menu under "CHART TOOLS"- "Format Selection".
Under "AXIS OPTIONS", change the "Bounds" - "Minimum" value to the number noted earlier,
et voilá:
Comments (2)
Commented:
Commented: