Adding the ROUNDUP function to an existing nested formula containing IFERROR & AVERAGEIF

znxm0i

New Member
Joined
May 27, 2014
Messages
29
Hi all,

I have the following formula and I need to add the ROUNDUP function to it so that it rounds up anything greater than 5 after the decimal point. Where do I add the ROUNDUP function to this formula please.

=IFERROR(AVERAGEIF('Data Raw'!$T$4:$T$136,"Commercial",'Data Raw'!$U$4:$U$136),0)

Thank you.
 

Excel Facts

Bring active cell back into view
Start at A1 and select to A9999 while writing a formula, you can't see A1 anymore. Press Ctrl+Backspace to bring active cell into view.
Are you sure that you really need ROUNDUP and not just ROUND, i.e.
Code:
[COLOR=#333333]=IFERROR(ROUND(AVERAGEIF('Data Raw'!$T$4:$T$136,"Commercial",'Data Raw'!$U$4:$U$136),0),0)[/COLOR]
 
Upvote 0
Are you sure that you really need ROUNDUP and not just ROUND, i.e.
Code:
[COLOR=#333333]=IFERROR(ROUND(AVERAGEIF('Data Raw'!$T$4:$T$136,"Commercial",'Data Raw'!$U$4:$U$136),0),0)[/COLOR]

Thank you for providing such a quick response.

Well the way I read the difference between ROUND and ROUNDUP is that I should use ROUNDUP if I wanted to roundup to the next nearest number if the value after the decimal points was greater than 5; and use ROUNDDOWN if was less than 5

If I just use the plain ROUND function will it round up and round down as applicable?

Also, one of my values is 128.30 but when I apply the revised formula to the cell it changes it to 128.00 do I have to use the Excel formatting function for decimals in conjunction with the ROUND function?
 
Upvote 0
ROUND rounds to the nearest number (so 5 and greater rounds up, 4 and less rounds down).
ROUNDUP ALWAYS rounds up. So any decimal will round up to the next highest number.
ROUNDDOWN does the opposite (always rounds down to the next lowest number).
Try playing around with each, and you will see what they do.

The formulas themselves do not determine the number of decimal places to show. That is handled by how the cell is formatted.
 
Upvote 0

Forum statistics

Threads
1,223,903
Messages
6,175,289
Members
452,631
Latest member
a_potato

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top