How to Show Top 10 in Tableau
Showing your top 10 performers - whether it's products, sales reps, or marketing channels - is one of the fastest ways to find out what's really driving your business. Instead of getting lost in a sea of data, a "Top 10" view helps you focus on the VIPs. This guide will walk you through several ways to create a Top 10 list in Tableau, from the quick and simple method to more flexible, interactive options.
Why Focus on the Top 10?
Filtering your data to show only the top performers isn't just about making your charts look cleaner, it’s a strategic analysis technique. The "Pareto Principle," or the 80/20 rule, often applies here: a small number of inputs (like your top 20% of customers) are likely responsible for a large percentage of your results (like 80% of your sales).
By isolating your Top 10, you can:
- Identify Key Drivers: Immediately see which campaigns, products, or regions are delivering the most value.
- Simplify Your Dashboards: Reduce noise and make your reports easier for your team to understand at a glance.
- Spot Winners Quickly: A Top 10 list makes it obvious who is over-performing, allowing you to double down on what works or replicate success in other areas.
Method 1: Using a Simple Filter (The Quickest Way)
This is the most direct method to show a Top 10 list in Tableau. It’s perfect for static reports or when you don’t need the end-user to change the number of items shown. Let’s say we want to see our Top 10 customers by sales.
Step-by-Step Instructions
- Build Your Basic View: Start by dragging your dimension and measure onto the view. For our example, drag
Customer Nameto Rows andSalesto Columns. Sort the view in descending order so the customer with the highest sales is at the top. - Add the Dimension to Filter: Drag the
Customer Namepill from the Dimensions pane directly onto the Filters card. - Configure the Filter: A dialog box will pop up. Navigate to the Top tab at the top of this box.
- Define Your Top 10:
Your chart will instantly update to show only the Top 10 customers based on their total sales. This method is incredibly fast, but it's hardcoded. If you want to see the Top 15, you'll have to go back in and edit the filter manually.
Method 2: Creating a Top N Parameter (For Interactive Dashboards)
What if you want your team to be able to see the Top 5, Top 10, or Top 20 without having to ask you to edit the report? This is where parameters shine. A parameter gives the user a control, like a slider or a text box, to change the "N" value in your Top N filter dynamically.
Step 1: Create the Parameter
- In the Data pane (on the left), click the small dropdown arrow next to the search bar and select Create Parameter.
- A configuration window will appear. Give your parameter a meaningful name, like "Select Top N".
- For Data type, choose Integer.
- For Allowable values, select Range. This will create a slider for a better user experience.
- Configure the range. You might set a Minimum of 1, a Maximum of 50, and a Step size of 1. You could also set the "Current value" to 10 as a default.
- Click OK. You’ll now see your new parameter in the Parameters section at the bottom of the Data pane.
Step 2: Create a Calculated Field to Use the Parameter
The parameter itself doesn't do anything - it's just a variable. Now you need to create a calculated field that uses the parameter to determine who makes the cut.
- Right-click in a blank space in the Data pane and select Create Calculated Field.
- Name it something like "Top N Filter".
- Enter the following formula, which uses a ranking function:
RANK(SUM([Sales])) <= [Select Top N]This formula calculates the rank of each customer based on their sum of sales and then checks if that rank is less than or equal to the number selected in your "Select Top N" parameter. The result will be either "True" or "False".
- Click OK.
Step 3: Apply the Filter
- Drag your newly created calculated field ("Top N Filter") onto the Filters card.
- In the dialog that appears, check the box for True and click OK.
Step 4: Show the Parameter Control
- Find your parameter ("Select Top N") in the Parameters section.
- Right-click on it and choose Show Parameter.
A control card will now appear on your dashboard (usually on the right side). Users can now use this slider or text box to change the number, and the chart will update in real-time to show the Top 5, Top 10, Top 25, or any other number within the range you defined.
Method 3: Using Sets for More Control
Sets are a powerful Tableau feature that let you group members of a dimension. A common use case is to identify your Top 10 customers and then compare them against everyone else. This is perfect for highlighting your most valuable customers in a chart without filtering everyone else out completely.
Step 1: Create the Set
- In the Data pane, find the dimension you want to filter (e.g., Customer Name).
- Right-click on it and go to Create > Set.
- Give your set a descriptive name, like "Top 10 Customers Set".
- Just like with the Simple Filter method, go to the Top tab.
- Select By field, set it to Top 10 by Sum of Sales, and click OK.
You now have a new Set in your Data pane under the Sets section. This set has two values: "In" (the customer is in the top 10) and "Out" (the customer is not).
Step 2: Use the Set in Your View
Here’s where sets become really useful. Instead of using the set as a filter, you can use it to group and color your data.
- Color by Set: Build a standard bar chart of all customers by sales. Now, drag your "Top 10 Customers Set" onto the Color tile in the Marks card. Your top 10 customers will be highlighted in one color, and all other customers will be colored gray. This is a fantastic way to draw attention to top performers without losing context of the whole.
- Group Others: You can also combine a Set with a calculated field to group everyone outside the top 10 into a single "Others" category.
IF [Top 10 Customers Set] THEN [Customer Name] ELSE "Others" ENDUse this new calculated field instead of Customer Name in your view, and you'll see your top 10 individuals listed, along with a single bar representing the combined sales of all other customers.
Advanced Tip: Finding the Top 10 Within Each Category
A common business question is, "Who are my top 5 sales reps in each region?" or "What are my top 10 products in each category?" This requires a different approach using table calculations.
- Build the initial view: Put Category and then Product Name on the Rows shelf, and SUM(Sales) on the Columns shelf. Sort so the products are descending by sales within each category.
- Create a Ranking Calculation: Create a new calculated field called "Rank Within Category" with the formula:
INDEX()This is simple, but its power comes from how we configure it.
- Add it as a Filter: Drag this new "Rank Within Category" calculated field to the visualization and make it discrete. Then, drag it to the Filters card. Select a range, such as 1 to 10.
- Edit Table Calculation Scope: This is the most important step. Right-click the filter you just added and select Edit Table Calculation. Under "Compute Using," choose Advanced. In the dialog, make sure that Category is in the Partitioning box and Product Name is in the Addressing box. This tells Tableau to restart the ranking (the INDEX()) for every new category.
Your view will now correctly show the Top 10 products for a given category, letting you perform much more detailed and contextual analysis.
Final Thoughts
Tableau provides several powerful ways to filter your data to show top performers, whether it's through a straightforward filter, an interactive parameter that empowers your users, or a dynamic set for comparative analysis. Mastering these techniques will help you move from simply showing data to presenting focused, valuable insights.
Of course, building these views, writing calculated fields, and configuring table calculations in any BI tool involves a series of manual steps. It's the reason we created an easier path with Graphed. Instead of clicking through menus to create filters and parameters, you can just ask a question like "show me a bar chart of my top 10 campaigns by revenue for last month." We connect directly to your data sources and instantly build a live, interactive dashboard for you, turning hours of report building into a 30-second task.
Related Articles
How to Enable Data Analysis in Excel
Enable Excel's hidden data analysis tools with our step-by-step guide. Uncover trends, make forecasts, and turn raw numbers into actionable insights today!
What SEO Tools Work with Google Analytics?
Discover which SEO tools integrate seamlessly with Google Analytics to provide a comprehensive view of your site's performance. Optimize your SEO strategy now!
Looker Studio vs Metabase: Which BI Tool Actually Fits Your Team?
Looker Studio and Metabase both help you turn raw data into dashboards, but they take completely different approaches. This guide breaks down where each tool fits, what they are good at, and which one matches your actual workflow.