Microsoft Office Tutorials and References

In Depth Information

**Rounding Numbers**

Rounding to
n significant digits

In some cases, you may need to round a value to a particular number of significant digits. For

example, you might want to express the value 1,432,187 in terms of two significant digits (that is,

as 1,400,000). The value 9,187,877 expressed in terms of three significant digits is 9,180,000.

If the value is a positive number with no decimal places, the following formula does the job. This

formula rounds the number in cell A1 to two significant digits. To round to a different number of

significant digits, replace the 2 in this formula with a different number.

=ROUNDDOWN(A1,2–LEN(A1))

For non-integers and negative numbers, the solution gets a bit trickier. The formula that follows

provides a more general solution that rounds the value in cell A1 to the number of significant

digits specified in cell A2. This formula works for positive and negative integers and non-integers.

=ROUND(A1,A2–1–INT(LOG10(ABS(A1))))

For example, if cell A1 contains 1.27845 and cell A2 contains 3, the formula returns 1.28000 (the

value, rounded to three significant digits).