2
votes

I'm trying to create something like a GANTT Chart where I would have start dates and end dates designated by a shape like a diamond and then the period of time in between connecting the start and end date shown as a line connecting the shapes. Does anyone have any tips on how to do that in tableau?

For data I have an identifier column, an event column, a date column, a start date column, and an end date column.

1
do you know how to create or modify jquery extensions on your own? - Scott Selby
Hi Scott, thank you for getting back to me so quickly on this. No, I am unfamiliar with jquery. - user3476463
What does the date column represent? I mean, how is that different than start date and end date? You can do this with a combo ghant/shape chart if you can shape your data appropriately first. - Alex Blakemore
Hi Alex, thank you for getting back to me on this. The date column will have dates besides the start date and end date of the individual contracts identified in the identifier column. In addition to contract start and end dates, there are also activations that occur in the data. How can I use a gantt/shape chart to connect shapes for start and end dates with a line, for the duration of the contract? - user3476463

1 Answers

2
votes

enter image description here

To make a basic Ghantt chart in Tableau, put the start date on the column shelf, convert it to continuous exact date. Put the identifier on the row shelf and change the mark type to Ghantt. This should get a short bar at the start date of each task, with a row per task (assuming the ids are unique per task).

Now you need to specify how long the bars should be by putting a field showing the number of days for each task on the size shelf. You can create a calculated field to compute those durations as datediff('day', contract_start, contract_end). Place that on the size shelf and you should be off to a decent start.

You can add more info to the tool tips and use color to show contract type or something else. add some reference lines by right clicking on the axis. You will need some tweaks in the calculated field to deal with things like null (unknown) end dates, maybe recurring tasks ...

If you want a few milestone markers, you can use reference lines or point annotations to add them by hand easily.

Or if you want to include milestones as shapes with your data, you can use a dual axis chart.

Here is an example showing how to combine shapes and bars into one char. The details vary slightly depending on how your data is organized, but if you examine how the data for this workbook is organized, how the data connection joins the tabs, and how the workbook displays the data, you should be able to adapt the approach to your own data. Just realize sometimes it is easier to revise the way your data is shaped to make the analysis simpler.

Also, you might want to consider if you need both planned and actual dates.

See also Gantt over time with summed bar