Which teams have the longest typical service time?
Why ask this?
A service manager comparing teams wants the typical job duration. The median keeps one unusually long job from determining which team usually takes longest.
Start with the sample data
Open source.csv. In the first row of source.csv, Team = Red, Service minutes = 2.
What to say
Draw a bar chart of the top two teams by median service minutes.
Processing time
- Recorded audio to chart ready
- 2.66 s
- Transcript to chart ready
- 0.63 ms
One local replay from recorded audio through transcription and native chart data preparation. Recording time and screen painting are excluded.
See the transcript in the composer

How the canvas produces the result
- CSV Input · Read the sample records
source.csv supplies 5 rows. These records are the inputs to the next step.
- Column Filter · columnfilter
The first output row contains Team = Red, Service minutes = 2.
- Rank · Assign a rank
The ordered rows receive positions starting at 1. Here, Red is #1, Red is #2, Red is #5.
- Aggregate · Take the minimum of Value position for each Team
If a category appears more than once, its records contribute to one result. The first output row contains Team = Red, min_Value position = 1.
- Joiner · Attach the group summary
Match Team to Team in the other branch of the canvas. The first matched row contains Team = Red, Service minutes = 2, Value position = 1, min_Value position = 1.
- Sort · Order the results
Sort by min_Value position (ascending), then Value position (ascending). The first rows in order are Red → Red → Red → Tan.
- Constant · Set Stable order
Use the same value on each row so a stable rank preserves the sorted order.
- Rank · Assign a rank
The ordered rows receive positions starting at 1. Here, Red is #1, Red is #2, Red is #3.
- Aggregate · Take the minimum of Position, Take the maximum of Position for each Team
If a category appears more than once, its records contribute to one result. The first output row contains Team = Red, min_Position = 1, max_Position = 3.
- Joiner · Attach the group summary
Match Team to Team in the other branch of the canvas. The first matched row contains Team = Red, Service minutes = 2, Value position = 1, min_Value position = 1, Stable order = 1, Position = 1, min_Position = 1, max_Position = 3.
- Math · Calculate Center distance squared
Apply (2 * [Position] - [min_Position] - [max_Position]) * (2 * [Position] - [min_Position] - [max_Position]) to each input row. The first row yields 4.
- Measure Filter · Keep the requested rows
The filter uses Center distance squared <= 1 in keep mode. 3 rows remain including Red.
- Aggregate · Average Service minutes for each Team
If a category appears more than once, its records contribute to one result. The first output row contains Team = Red, avg_Service minutes = 3.
- Column Renamer · Prepare the output columns
avg_Service minutes becomes median_Service minutes. The result exposes Team, median_Service minutes.
- Sort · Order the results
Sort by median_Service minutes (descending), then Team (ascending). The first rows in order are Tan → Red.
- Rank · Assign a rank
The ordered rows receive positions starting at 1. Here, Tan is #1, Red is #2.
- Measure Filter · Keep the requested rows
The filter uses rank <= 2 in keep mode. 2 rows remain including Tan.
- Column Renamer · Prepare the output columns
Remove rank. The result exposes Team, median_Service minutes.
- Charts · Draw the bar chart
Use Team for the categories and median_Service minutes for the plotted values.

The chart

| Team | median_Service minutes |
|---|---|
| Tan | 9 |
| Red | 3 |
How to use the result
For Team Tan, the sample reports median_Service minutes of 9.
Synthetic test audio. Screenshots from the recorded workflow in n0is.