# Rounding when already an integer

1. ## Rounding when already an integer

I have a column of prices, and want to round them down to the nearest lower \$, however when I use ROUNDDOWN, if the price is already at 0c eg \$164.00, it rounds it down to the next lowest integer (in this example \$163). What formula can I wrap around my ROUNDDOWN so it leaves the number alone if it is already a whole number?

2. ## Re: Rounding when already an integer

If I understand correctly try something like
Formula:
`Please Login or Register  to view this content.`

3. ## Re: Rounding when already an integer

Hi Jo,

I think your \$164.00 must be a little less and you are simply displaying the closest integer. RoundDown will keep an number as it is, if it is already equal to that number. That is 164 rounds down to 164, it does not go down to 163 unless it isn't really 164 (but a little less).

4. ## Re: Rounding when already an integer

@Jo Ross.... Change your formula to something of the form =ROUNDDOWN(ROUND(A1,2),0).

If you temporarily format the cell that appears to be 164.00 as Currency (or whatever) with 15 decimal places, I suspect that you will see that it is less than 164.00.

It only appears to be 164.00 because your format rounds the appearance to only 2 decimal places.

By explicitly rounding to 2 decimal places first, you will rounddown the value as it appears.

Alternatively, if the value in A1 is calculated, it might be prudent to round the formula in A1.

In general, if you expect a calculation to be accurate to some number of decimal places (2, in your case), you should explicit round to that number of decimal places.

(Not to an arbitrarily larger number of decimal places, as some people suggest).

5. ## Re: Rounding when already an integer

Originally Posted by MarvinP
Hi Jo,

I think your \$164.00 must be a little less and you are simply displaying the closest integer. RoundDown will keep an number as it is, if it is already equal to that number. That is 164 rounds down to 164, it does not go down to 163 unless it isn't really 164 (but a little less).
This is not how ROUNDOWN works for me, something must be off about your settings or value.

Ex, value in A2, formula in B2:
Formula:
`Please Login or Register  to view this content.`

A2= 164, formatted as currency, B2 = 164
A2= 164.01, formatted as currency, B2 = 164
A2= 163.99, formatted as currency, B2 = 163

All of which is exactly what I expect.

There are currently 1 users browsing this thread. (0 members and 1 guests)

#### Posting Permissions

• You may not post new threads
• You may not post replies
• You may not post attachments
• You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1