Cost per unit by plant
Why ask this?
A buyer comparing plant costs needs a per-unit figure that reflects actual volume. A small expensive batch should contribute only its share of units.
Start with the sample data
Open source.csv. In the first row of source.csv, Plant = A, Cost = 12, Units = 1.
What to say
Show a bar chart of average cost per unit by plant. Divide total cost by total units, ignoring rows with zero units.
Processing time
- Recorded audio to chart ready
- 5.32 s
- Transcript to chart ready
- 0.47 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.
- Measure Filter · Keep the requested rows
The filter uses Units > 0 in keep mode. 3 rows remain including A.
- Aggregate · Sum Cost, Sum Units for each Plant
If a category appears more than once, its records contribute to one result. The first output row contains Plant = A, sum_Cost = 20, sum_Units = 10.
- Math · Calculate Average cost per unit
Apply [sum_Cost] / [sum_Units] to each input row. Set Decimal places to 2 to round the result. The first row yields 2.
- Charts · Draw the bar chart
Use Plant for the categories and Average cost per unit for the plotted values.

The chart

| Plant | Average cost per unit |
|---|---|
| A | 2 |
| B | 2.25 |
How to use the result
For Plant A, the sample reports Average cost per unit of 2.
Synthetic test audio. Screenshots from the recorded workflow in n0is.