Learn Tableau How to highlight the past, present and future automatically using Tableau

How to highlight the past, present and future automatically using Tableau

In this video we learn in Tableau Desktop how a simple calculated field can create a dimension, that can be applied to a charts colors and automatically highlight the past, present and future dates. This is a simple but powerful technique, enabling the viewers to infer that all of the data points should not be treated equally e.g. can’t affect the past, can affect the present, the future results haven’t happened yet. Otherwise your viewers might make incorrect assumptions about your charts, which can never work out well for anyone.

Copy and paste this equation into a calculated field in Tableau to create a new dimension:

IF DATEDIFF("quarter",[Date],TODAY()) > 0 THEN "Past"
    ELSEIF DATEDIFF("quarter",[Date],TODAY()) = 0 then "Present"
    ELSEIF DATEDIFF("quarter",[Date],TODAY()) < 0 then "Future"
END

Do you have a different technique to achieve this, a good example of it in action or if this helped you out somehow? Let me know in the comments below.

LEAVE A REPLY

Please enter your comment!
Please enter your name here

Follow

Tableau PublicYouTubeTwitterFacebookLinkedInInstagramEmail Newsletter

Latest Articles

Groceries made easy using Google Sheets

Have you ever wanted to help out more around the house, but not have it take up a lot...

Time Saver Tool v2.0

Have you ever discovered a way to speed up a process but cannot convince others to do it? Felt like you don't...

SG Tableau User Group Oct 2020

The SG Tableau User Group just wrapped up it's October virtual livestream event, which you can now watch on YouTube here. It...

Find insights beyond the summary stats (w/ data viz)

In this video we will see how summary stats can be misleading and the importance of data viz to easily dig deeper into the numbers beneath them.

Data Studio Community Livestream | Jun 2020

Welcome to the first Data Studio Community Livestream - you'll see 4 speakers covering a wide variety of topics, which should help any and...