1 of 1 people found this helpful
Change your date field to continuous field and tableau will fill all the missing dates since its a continuous field.
For a sample data like this
In the tableau dashboard it looks like this with discrete and continuous fields.
This shows only the dates that are available in the excel shown above. If you change your date field from discrete to continuous, tableau fills the spaces in middle.
One problem with this is this view ignore the data being unavailable at some dates (example Jan 3). This may give false interpretation to users. Use ISNULL to convert missing data points to either 0 or NULL to show exact data.
For the reference band, you need a min and max value.
So create them using these calculations,
The flower braces around the calculation means they are fixed to overall table. And these 2 calculated fields provide max and min ranges of the reference band as your Maximum date and its previous day.
Convert these fields to continuous fields and add them to the detail mark.Use them in creating your reference band.
Similarly, create for 3 days and use them to create another band.
I took a similar approach as Jeevan except I used a calculated field for TODAY which is used in a dual axis. This helps when there's no data for the last day and you still want to keep the reference bands. The workbook is attached along the calculations.
Hope this helps!
Today.twbx 1.1 MB