Last Modified Date: 20 Jul 2023
Environment
- Tableau Desktop
Answer
This example uses Sample - Superstore data.- Place Category and Region on Columns.
- Place Profit on Rows.
- Select Analysis > Create Calculated Field.
- Name the calculated field, for example "Reference Line". Enter a calculation similar to the following, then click OK:
CASE Category
WHEN "Furniture" Then 10000
WHEN "Office Supplies" Then 40000
WHEN "Technology" then 30000
END - Place Reference Line on Detail.
- On the Marks card, Right-click Reference Line and select Measure > Average.
- On the Analytics tab, select Average Line and then Pane.
- Right-click your new reference line and select Edit. Select and enter the following, then click OK:
- Scope: Per Pane
- Value: AVG(Reference Line), Average
- Label: Custom, Goal
Thank you for providing your feedback on the effectiveness of the article.
Open new Case
Continue Searching
Knowledge Base
Community
Product Help
Training and Tutorials