Filtering is an essential part of analyzing data. This article describes the many ways you can filter data from your view. It also describes how you can display interactive filters in the view, and format filters in the view. Show
Watch a Video: To see related concepts demonstrated in Tableau, watch these free training videos: Ways to Filter(Link opens in a new window) (2 minutes), Where Tableau Filters(Link opens in a new window) (4 minutes), Using the Filter Shelf(Link opens in a new window) (7 minutes), Interactive Filters(Link opens in a new window) (4 minutes), and Additional filtering topics(Link opens in a new window) (7 minutes). Use your tableau.com(Link opens in a new window) account to sign in. Filtering Order of OperationsBefore you begin filtering data in Tableau, it's important to understand the order in which Tableau executes filters in your workbook. Tableau performs actions on your view in a very specific order; this is called the Order of Operations. Filters are executed in the following order:
To learn more, see Tableau's Order of Operations(Link opens in a new window). Note: When you drag a discrete dimension to the Filters shelf, the Filter dialog box offers four tabs for filtering: General, Wildcard, Condition, and Top. The settings on each of these tabs are additive starting with the General tab; what you set on each tab will affect the filter results on each tab to the right. For details on the Filter dialog box, see Drag dimensions, measures, and date fields to the Filters shelf and Filter categorical data (dimensions). Select to keep or exclude data points in your viewYou can filter individual data points (marks), or a selection of data points from your view. For example, if you have a scatter plot with outliers, you can exclude them from the view so you can better focus on the rest of the data. To filter marks from the view, select a single mark (data point) or click and drag in the view to select several marks. On the tooltip that appears, you can:
Note: These filtering options are not available if a Wildcard Match filter is already specified for the same field. See Drag dimensions, measures, and date fields to the Filters shelf (Link opens in a new window) to learn more about Wildcard Match filters. You can also select headers to filter them from your view. To filter entire rows or columns of data from your view, select the header in the view. On the tooltip that appears, select to Exclude or Keep Only the selected data. When you select a table header that is part of a hierarchy, all of the next level headers are also selected. For example, the view shown below consists of two unrelated dimensions placed on the Columns shelf, and two levels of the same hierarchy placed on the Rows shelf. The selected row headers include the Furniture member of the Category dimension, and the Binders and Labels members of the Sub-category dimension. When Furniture is selected, all members from the next (inner) level in the hierarchy are automatically selected. In this case, that means the Bookcases, Chairs, Furnishings, and Tables members.
Drag dimensions, measures, and date fields to the Filters shelfAnother way to create a filter is to drag a field directly from the Data pane to the Filters shelf.
When you add a field to the Filters shelf, the Filter dialog box opens so you can define the filter. The Filter dialog box differs depending on whether you are filtering categorical data (dimensions), quantitative data (measures), or date fields. Filter categorical data (dimensions)Dimensions contain discrete categorical data, so filtering this type of field generally involves selecting the values to include or exclude. When you drag a dimension from the Data pane to the Filters shelf in Tableau Desktop, the following Filter dialog box appears:
Important Note: Each tab adds additional definitions to your filter. For example, you can select to exclude values under the General tab, and also add limits under the Top tab. Selections and configurations from both tabs are applied to your filter. At any time, you can see the definitions of your filter under Summary on the General tab. Filter quantitative data (measures)Measures contain quantitative data, so filtering this type of field generally involves selecting a range of values that you want to include. When you drag a measure from the Data pane to the Filters shelf in Tableau Desktop, the following dialog box appears:
Select how you want to aggregate the field, and then click Next. In the subsequent dialog box, you're given the option to create four types of quantitative filters: Range of Values: Select the Range of Values option to specify the minimum and maximum values of the range to include in the view. The values you specify are included in the range. At Least: Select the At Least option to include all values that are greater than or equal to a specified minimum value. This type of filter is useful when the data changes often so specifying an upper limit may not be possible. At Most: Select the At Most option to include all values that are less than or equal to a specified maximum value. This type of filter is useful when the data changes often so specifying a lower limit may not be possible. Special: Select the Special option to filter on Null values. Include only Null values, Non-null values, or All Values. Note: If you have a large data source, filtering measures can lead to a significant degradation in performance. It is sometimes much more efficient to filter by creating a set containing the measure and then apply a filter to the set. For more information about creating sets, see Create Sets(Link opens in a new window). Filter datesWhen you drag a date field from the Data pane to the Filters shelf in Tableau Desktop, the following Filter Field dialog box appears:
You can select whether you want to filter on a relative date; filter between a range of dates; or select discrete dates or individual dates to filter from the view.
Filter table calculationsTo create a table calculation filter, create a calculated field, and then place that field on the Filters shelf. Filters based on table calculations do not filter out underlying data in the data set, because table calculation filters are applied last in the order of operations. This means Tableau evaluates any table calculations in the view first, and then applies table calculation filters on the results in the current view. Apply table calculation filter to totalsWhen you show totals in a view and you want a table calculation filter to apply to the totals, you can select Apply to totals in the drop-down menu for that filter (on the Filters shelf). This option lets you decide when a table calculation filter should be applied to totals.
This options is available when you show totals in the view, and you add a table calculation filter to the view. Select Apply to totals to apply the table calculation filter to all of the results in the table, including the totals. Display interactive filters in the viewWhen an interactive filter is shown, you can quickly include or exclude data in the view. Note: In web authoring, interactive filters are automatically added to the view when you drag a field to the Filters shelf. To show a filter in the view:
The field is automatically added to the Filters shelf (if it is not already being filtered), and a filter card appears in the view. Interact with the card to filter your data. Note: In Tableau Desktop, you can add an interactive filter to the view for a field that is not currently used in the view. To do so, In the Data pane, click the field drop-down menu, and then select Show Filter. Set options for filter card interaction and appearanceAfter you show a filter, there are many different options that let you control how the filter works and appears. You can access these options by clicking the drop-down menu in the upper right corner of the filter card in the view.
Some options are available for all types of filters, and others depend on whether you’re filtering a categorical field (dimension) or a quantitative field (measure). You can customize how filters appear in the view, in dashboards, or when published to Tableau Server or Tableau Cloud. Here are some of the general filter card options:
Filter card modesYou can control the appearance and interaction of your filter card in the view by selecting a filter card mode. To select a filter card mode, in the view, click the drop-down menu on the filter card and then select a mode from the list.
The types of filter card modes you see in the list of options depend on whether your filter is on a dimension or a measure. Below you can find brief descriptions of the types of filter card modes available for dimensions and measures. For dimensions, you can choose from the following filter modes:
For measures, you can choose from the following filter modes:
Note: When you expose a filter for Measure Values or Measure Names as a single value list, selecting All will automatically convert the
filter to a multiple values list. For information on Measure Values and Measure Names, see Measure Values and Measure Names. Customize filter cardsIn addition to the general filter options and the filter modes, you control how your filter appears in the worksheet, on dashboards, or when published to the web even further in Tableau Desktop. To customize filters, click the filter card drop-down menu and select Customize.
You can select from the following options:
See Also
What displays a list of data values from which the user can choose in access?Learn about the types of list box controls. Access provides two list controls for forms — the list box and the combo box. List box The list box control displays a list of values or choices. The list box contains rows of data, and is usually sized so that several rows are visible at all times.
Which of the following is used to find data in a database?Queries. Queries can perform many different functions in a database. Their most common function is to retrieve specific data from the tables.
Which of the following input mask characters requires a user to enter a letter or a number?Characters that define input masks. Which of the following refers to the process of verifying the accuracy or integrity of data?The process of verifying the accuracy, or integrity, of data is known as data integrity.
|