Last Modified Date: 02 Jun 2017
Step 1: Set up the View
- In Tableau Desktop, connect to the Superstore Sales sample data.
- Drag Order Date to Rows.
- Right-click Order Date on Rows, and then select Month.
- Right-click Order Date on Rows again, and then select Discrete.
- Right-click Order Date on Rows again, and then select Sort.
- In the Sort dialog box, under Sort Order, select Descending, and then click OK.
- Drag Sales to Text.
- Right-click Sales on Text, and then select Quick Table Calculation > Moving Average.
Step 2: Filter the View
- Select Analysis > Create Calculated Field to create a calculated field.
- In the Calculated Field dialog box that opens, enter a name for the field. In the example workbook, this field is named Date Lookup Filter.
- In the formula field, create a calculated field similar to the following, and then click OK:
- Under Measures, right-click Date Lookup Filter, and then select Convert to Continuous.
- Drag Date Lookup Filter from Measures to Filters.
- In the Filter dialog box that opens, select the desired dates, and then click OK.
Additional InformationWhen a dimension is placed on the Filters shelf, Tableau Desktop filters out the underlying data as well as the data in the view. When using running sum, percent change, or moving average calculations, this filtering will cause the data in the view to change. Filters based on table calculations do not filter out underlying data. Instead, the data is hidden from the view, allowing dimension members to be hidden from the view without impacting the data in the view.
Community Forum: How to display a graph of "active events" over time
Thank you for providing your feedback on the effectiveness of the article.
Open new Case
Training and Tutorials