Tidy numbers with ROUND
Work out the average price customers really paid for each product, then round it to whole dollars with ROUND.
You will learn to
- Round a result to a chosen number of decimal places
- Tell rounding a value apart from formatting it
- Wrap one function around another
How it works
`ROUND(number, digits)` rounds a number to the number of decimal places you ask for. `2` keeps cents, `0` gives whole numbers, and `-1` even rounds to the nearest ten.
Formatting and rounding are not the same thing. A display format only changes how a number **looks**; the full value is still there underneath. `ROUND` changes the value itself, which matters when the number is compared, labeled or used in another measure.
You can wrap `ROUND` around any calculation. DAX works from the inside out: it does the division first, then rounds the result.
Practice it hands-on with a real data model and a live report that updates as you type.
Sales in Thousands = ROUND(DIVIDE([Total Sales], 1000), 1)