From a CSV file to a report
In this tutorial you turn a small CSV file of sales into a one-page PDF report: a table of revenue by region and a bar chart of it. You start from an empty document and place every node yourself. It uses 12 nodes.
You need: Divooka Explore or Divooka Compute, and Your first program done once, so you know how to place and wire nodes. No internet connection is needed.
You will use: the Data Analytics and Plotting toolboxes.
1. Make the data file
Open Notepad, paste these lines, and save the file as sales.csv in your Documents folder.
Date,Region,Product,Units,Unit Price
2026-01-05,North,Kettle,4,39.90
2026-01-06,South,Toaster,2,54.50
2026-01-09,East,Kettle,6,39.90
2026-01-12,West,Blender,1,89.00
2026-01-14,North,Toaster,3,54.50
2026-01-17,East,Blender,2,89.00
2026-01-20,South,Kettle,5,39.90
2026-01-22,West,Kettle,2,39.90
2026-01-25,North,Blender,2,89.00
2026-01-27,East,Toaster,4,54.50
2026-01-29,South,Blender,1,89.00
2026-01-31,West,Toaster,3,54.50
Each line is one sale. The first line holds the column names.
2. Create the document
- In Divooka, press
Ctrl+Nand save the document asSales Report. - Keep Flows as the entry graph and press Create document.
In Divooka Compute, choose the Data Analytics workload on the Choose a workload card. It brings every node this tutorial uses.
A Flows graph runs the nodes you mark Active, and every node they need. You will mark one node active at each checkpoint.
3. Read the file
- Press
Ctrl+Space, typeRead CSVand pressEnter. - In its Path box, type the full path of the file, for example
C:\Users\Ada\Documents\sales.csv.
Leave the other inputs as they are. Delimiter auto finds the comma itself, Header says the first line holds the names, and Infer Types reads Units and Unit Price as numbers and Date as a date.
Checkpoint. Select Read CSV, press Space to mark it active, and press F5. The node shows done. With it selected, the Properties panel previews the table: 12 rows and 5 columns. Press Space again to take the mark off.
4. Add a revenue column
The file has units and a price, but not the revenue of each sale.
- From Read CSV's output, place Formula Column.
- Name:
Revenue. - Formula:
[Units] * [Unit Price]
A formula works on each row. Put a column name in square brackets; the brackets are optional when the name has no spaces. The new column is added at the end of the table.
5. Total it by region
- From Formula Column's output, place Group And Summarize.
- Group By:
Region. - Summaries:
Sales = COUNT(), Units = SUM(Units), Revenue = ROUND(SUM(Revenue), 2)
Group And Summarize makes one row for each region. Each summary becomes a column, named by the word before =.
- From its output, place Sort Rows. Columns:
Revenue. Turn Descending on.
Checkpoint. Mark Sort Rows active and run. Its table should hold:
| Region | Sales | Units | Revenue |
|---|---|---|---|
| East | 3 | 12 | 635.4 |
| North | 3 | 9 | 501.1 |
| South | 3 | 8 | 397.5 |
| West | 3 | 6 | 332.3 |
Take the active mark off again.
6. Draw a chart
A chart reads its data as named series, so the table goes through one node first.
- From Sort Rows' output, place Table As Series.
- From Table As Series' output, place Bar Chart of Table.
- Category:
Region. Value:Revenue. Title:Revenue by region.
7. Write the report
A report is built step by step: each node takes the report so far, adds one thing and passes it on.
- Place New Report. Title:
Sales report. Subtitle:January 2026. Author: your name. - From its output, place Add Heading. Text:
Revenue by region. - From Add Heading's output, place Add Table. Wire Sort Rows' output into its Table input. Title:
Sales, units and revenue. - From Add Table's output, place Add Chart. Wire Bar Chart of Table's output into its Chart input. Caption:
East sold the most. - From Add Chart's output, place Save Report. Path:
Sales Report.pdf. - From Save Report's Path output, place Print Line.
8. Run it
Select Print Line, press Space to mark it active, and press F5. Divooka runs every node Print Line depends on, which is all 12.
The console (Ctrl+` ) prints where the report went, for example:
C:\Users\Ada\Documents\Divooka\Reports\Sales Report.pdf
A file name on its own goes into the Reports folder under Documents\Divooka. Open the PDF: it has the title, the date it was made, the heading, the table and the chart on A4 pages.
Press Ctrl+S to save the document.
Try more
- Another format. Change Save Report's Path to
Sales Report.pptxorSales Report.docx. The extension decides the format. In PowerPoint and Word, the chart is a native chart with its data inside. - More numbers. Add
Average Price = ROUND(MEAN([Unit Price]), 2)to the summaries. - Two levels. Add
Productto Group By as a second column afterRegion. - Your own data. Point Read CSV at another file and change the column names in the formulas. Nothing else needs to change.
- Key figures. Add Add Key Figure after New Report to show one large number, such as the total revenue.
If something goes wrong
- Read CSV fails. Check the path. It must be the full path, with the file name and
.csv. - A column is not found. Column names must match the file exactly, spaces and capitals included.
[Unit Price]needs its brackets. - Revenue looks wrong. Check that Units and Unit Price were read as numbers: Infer Types must be on.
Where next
- Data analytics: what else Divooka does with tables.
- Data Analytics > Engineering - Machine Failures in the examples: the same steps on 10,000 rows, with key figures and four charts.
- Data Analytics toolbox: every category of nodes.