The Sort and Limit Chart Transform allows you to order your grouping axis values and display the top or bottom values in the Chart.
For example, if I wanted to see my top three performing Sales Reps, I could Sort by Sum of Deal Amount Descending, and Limit my chart to the Top 3 values.
How to use the Sort & Limit Chart Transform
To define a Sort order in your Chart, open the Sort & Limit Chart Transform and select which column you want to Sort by. You can Sort by the Chart’s Grouping (ex: Sales Rep) or by a Data Series (ex: Sum of Deal Amount) in the Chart.
Once you have selected which column you want to Sort by, you define the Sort order. If you Sorted your Chart by the Grouping column, you can order the values A -> Z (alphabetical order) or Z -> A (reverse alphabetical order) for a text grouping. If your grouping column is numeric, you can order ascending or descending.
If you Sort the Chart by a Data Series (ex: Sum of Deal Amount), you can select between ascending and descending.
Sort and Limit is available for any non-date grouping for all Series Charts. Sort and Limit in Table Charts is available for all data types (including dates). If you apply a Sort by on a date column in a table chart, you can apply a New -> Old or Old -> New ordering.
Limit Group Count to
The Limit Group Count to setting allows you to display the top or bottom values based on the applied Sort order. To enable limiting, you must first apply an explicit Sort order to your chart. Once a Sort order has been defined, you can select “Top” or “Bottom” and then define the number of values you want to display. Your Chart will update as you input a limit value.
Remove Sort & Limit
To remove Sort & Limit, select “None” in the Sort by dropdown. Setting the Sort by selection to “None” also clears the Limit. However, if you wish to only remove the Limit, select “None” in the Limit Group Count to dropdown.
How does Sort & Limit behave in Expanded View?
Raw Data View
The Raw Data View of a metric shows all of the data filtered down according to the Chart’s Date Range and any Custom Filters applied. If you limit your chart’s value to the Top 3, the Raw Data View will still show transactional level data that was filtered out of the chart by Sort & Limit.
Date Range and Custom Filtering
Sort & Limit is run after the Filter Transform. This means if you apply a Filter in Expanded View (Custom Filter or Date Range), Sort & Limit is rerun on the subset of data created by the Filter statement.
For example, my “Top 3 Sales Rep” metric displays Stanley, Kevin, and Pam as the overall top performers. If I apply a Filter where Lead Source equals Organic Traffic, my metric then updates to show me the Top 3 Sales Reps for only Organic Traffic: Kevin, Pam, Jim.
How does Sort & Limit work with Dashboard Filtering?
Dashboard Filtering is also run before the Sort & Limit transform, thus applying a Dashboard Filter produces the same behavior as applying a custom Filter in Expanded View.
- How do I apply a Custom Sort?
This functionality is not currently available. You must select from the default sorting options (ascending, descending, A -> Z, Z -> A, Old -> New, New -> Old).
- How do I sort by a column in my data table that is not charted?
This functionality is not currently available, you may only sort by the Chart’s Grouping or Data Series' selection.