This series looks at some of the things that can go wrong in an Excel spreadsheet and at what we can do to avoid or resolve the issue. We start with the basics of making sure our numbers add up.
Introduction
In part 1, we will be starting with a pretty basic problem – our numbers don’t add up.
Rounding
Although displaying our numbers to round pounds displays our values of 41.5 as 42, Excel continues to use the underlying value of 41.5 in any calculations that use the contents of that cell, irrespective of the cosmetic number format that we have applied to it. Hence, we are actually adding up our 2 values of 41.5 to give us our total of 83, rather than adding up the values of 42 that the cells display:
Excel has several different functions that can help us avoid rounding errors. The ROUND() function simply takes a value, or preferably a reference to a cell containing a value, and rounds it to the number of decimal places entered as the second argument of the function:
=ROUND(B4,0)
Positive numbers entered as the second argument increase the number of decimal places to which the number is rounded. Negative numbers round to the left of the decimal place, so entering the second argument as -3 will round to thousands for example.
If cell B4 contains the value 41.5, or a calculation that returns a value of 41.5, then our formula will round the value to 42. We could use ROUND() to round both our 41.5 values to 42 so that our total would be based on 42 rather than 41.5, and our two values displayed as 42 would add up to 84, rather than 83:
Always avoid a plus one
Adherence to principle 14 of the Twenty Principles for Good Spreadsheet Practice should help prevent this possibility:
Next time
Additional resources
You can explore all aspects of Excel, including rounding and the different rounding functions, in the ICAEW archive:
Archive and Knowledge Base
This archive of Excel Community content from the ION platform will allow you to read the content of the articles but the functionality on the pages is limited. The ION search box, tags and navigation buttons on the archived pages will not work. Pages will load more slowly than a live website. You may be able to follow links to other articles but if this does not work, please return to the archive search. You can also search our Knowledge Base for access to all articles, new and archived, organised by topic.