Home » Tableau » Easy to create Tableau YTD Filter & Full Year Filter

Easy to create Tableau YTD Filter & Full Year Filter

Below content describe the Step wise guide how to create Tableau YTD filter and Full Year Filter option in Tableau. 

YTD called as year to date meaning the sum up of financial numbers from January to till date. Lets take example: if you are calculating YTD for sales number in month of August for 2020, then the YTD will be Sum of Sales from January to August.

For creating YTD (Year to date) and Full year filters you need one field as date. And on date field,  you will create Parameters and Calculated fields. with the combination of these two you can easily create filter and interact with your chart and dashboard in tableau.

1. First create Parameter in Tableau

Create a new parameter and let’s call it “YTD/FY Selection” as a String, just click on triangle shape on fields shelf in tableau and select parameter.

then in parameter name the parameter and put below two options in parameter as string. This will help you to select which one you would like to filter.

1.YTD
2.Full Year

2. Second create calculated field

With name YTD/FY Field, Below is the calculated formula used on date field and with if condition it is changing the date format as per the Parameter selection

IF [YTD Selection] = 'YTD'
THEN
   IF MONTH([Date]) <= month(TODAY()-1)
   THEN 'Show'
   ELSE 'Hide'
   END
ELSEIF [YTD Selection] = 'Full Year'
THEN
    IF year([Date]) <= year(TODAY())
    THEN 'Show'
    ELSE 'Hide'
    END
ELSE 'Hide'
END

3. Set in Chart area:

Now drag parameter as filter option to see the drop down filter. And from filter you can choose which one your would like to see in your visualization or chart or table in tableau. These are three steps to create YTD and Full Year Filter option in Tableau. Once you will follow all 3 steps you can put the filter option on your dashboard as well. 

Below are the few more chart can be created in tableau, steps wise guide for easy to design.

Gender Bar Chart in Tableau

Bar Chart in Tableau