Recently Tableau has published a white paper on LOD or level of details computation. In the paper, there is a chart on the precedence of filters which is very nice.
Especially this shows by what precedence various filters work in succession. It is essential for any Viz developer to understand this precedence and use them accordingly.

I found that the chart above ignored sets, which are also a class of filters by its own.

Sets as Filter
Sets are a special class of filters which narrow the scope of the data set. When you create a set and put it on the filter shelf, all the following calculations will take place in the context of the set. The filter conditions for the set can be configured in this interface:
The definition of the filter can be based on dimension or measure or both. Only the data that meet the conditions will be included in the set.

For a dimension, right click it, we can see a filter settings like this
Note that the wildcard option can also create a set. But this is not included in the Create Set menu!

So, there are 4 ways to create a set filter or these 4 filters are all set filters:
- General: handpick a list
- Wildcard
- Conditional
- Top

These conditions can be all used in parallel to define a set!

Revised Precedence of Filtering
Here is the one I draw as the revised precedence of filtering.
All filters except the last one reduce the number of rows/records or narrow the scope of the original data set. 

The last one - Table Calc Filters - will only select the part of the calculation results that are of interest to the viewer, and hide the rest of the results. They will by no means remove a single bit of data.

Context filters are preceding set filters and all the rest. Set filters further narrow the scope of data to those within the set. They act like context filter to the following dimension filters. 

We have built an example to illustrate how set filters work with dimension filters and LOD.

Sets vs Dimension Filter
In the example, a set is created for top 10 customers in terms of total sales. The category filter can have multiple options. All the category options will be calculated within the top 10 customers. The set provides the context for the category filter here.

Sets vs LOD
LOD will work independent of sets. So sets have no effect on LOD calculations. The following example shows that with the set in filter shelf, we can still use LOD to calculate the minimum sales per customer per category over the entire customer base.
The examples are included in a workbook which can be downloaded.

In conclusion, we showed here where sets work in the precedence of filtering. They are after context filters and LOD, and before dimension filters.





0

Add a comment

(Refresh the page if you want to view the gif image multiple times. Or go to Tableau Public and click the button at the top-right corner.)

Jake and I collaborated on a dashboard. He told me that he learnt a way to create an in-place help page in Tableau. He first saw it at a conference somewhere and couldn't recall who the speaker was. So I am blogging here about it but the credit goes to somebody else. If anyone knows who the original creator is, leave a comment below.

The key idea is to float a semi transparent worksheet on top of the dashboard, where a help text box is strategically placed on top of each chart. This way, we can explain how to view each chart and what data points are important, etc. This worksheet is collapsible by a show/hide button. 

Below I would like to show how this worksheet can be constructed.

1. Sheet with a single data mark.

  • Double click the empty space in Marks panel and add two single quotes. Make the null pill a text label. This creates a single null mark.
  • Set the view as "Entire View"

2. Create an show/hide button

  • Go to the target dashboard
  • Drag a floating vertical container to the dashboard, making it cover all the area of interest.
  • Drag the Single Null Mark sheet and drop it into the above container. Hide the sheet title.
  • Create an open/close button for the container and place the button at the top-right corner.

3. Add annotations

  • Format the sheet background opacity as 70% in the layout manager             
  • Select area annotations and place them anywhere of interest. 
  • Write help text and format it to highlight important messages.  
  • The text can serve as functional guide and/or insight guide.

Here is an example. Feel free to download the workbook and explore. Click the "i" button at the top-right corner to view the in-place help. 

0

Add a comment

Blog Archive
Loading
Dynamic Views theme. Powered by Blogger. Report Abuse.