ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Different kind of rounding (https://www.excelbanter.com/excel-discussion-misc-queries/214374-different-kind-rounding.html)

Sarah_Lund

Different kind of rounding
 
I need help with this one...

If the 3rd digit after the decimal is not a zero, I need to round up the 2nd
digit, otherwise leave the number as is
Examples:
4.240 would be 4.24
4.241 would be 4.25

I'd like to be able to do this in one step/one formula.
Any suggestions??
Thank you,
Sarah


Gary''s Student

Different kind of rounding
 
With a value in A20:

=IF(RIGHT(1000*A20,1)=0,A20,ROUNDUP(A20,2))

--
Gary''s Student - gsnu200821


"Sarah_Lund" wrote:

I need help with this one...

If the 3rd digit after the decimal is not a zero, I need to round up the 2nd
digit, otherwise leave the number as is
Examples:
4.240 would be 4.24
4.241 would be 4.25

I'd like to be able to do this in one step/one formula.
Any suggestions??
Thank you,
Sarah


Jerry W. Lewis

Different kind of rounding
 
=IF(ROUND(x,3)=ROUND(x,2),ROUND(x,2),ROUNDUP(x,2))

Jerry

"Sarah_Lund" wrote:

I need help with this one...

If the 3rd digit after the decimal is not a zero, I need to round up the 2nd
digit, otherwise leave the number as is
Examples:
4.240 would be 4.24
4.241 would be 4.25

I'd like to be able to do this in one step/one formula.
Any suggestions??
Thank you,
Sarah


David Biddulph[_2_]

Different kind of rounding
 
or =ROUNDUP(ROUND(x,3),2) ?
--
David Biddulph

"Jerry W. Lewis" wrote in message
...
=IF(ROUND(x,3)=ROUND(x,2),ROUND(x,2),ROUNDUP(x,2))

Jerry

"Sarah_Lund" wrote:

I need help with this one...

If the 3rd digit after the decimal is not a zero, I need to round up the
2nd
digit, otherwise leave the number as is
Examples:
4.240 would be 4.24
4.241 would be 4.25

I'd like to be able to do this in one step/one formula.
Any suggestions??
Thank you,
Sarah




joeu2004

Different kind of rounding
 
On Dec 21, 7:56*am, Sarah_Lund
wrote:
If the 3rd digit after the decimal is not a zero,
I need to round up the 2nd digit, otherwise leave
the number as is
Examples:
4.240 would be 4.24
4.241 would be 4.25


Caveat emptor: it is not clear what you want to do with 4.2405, for
example. A literal interpretation would say that you want 4.24. But
perhaps you mean "if the 3rd digit after the decimal point after first
rounding to 3 decimal places". It would behoove you to test any
solution with 4.2405 to be sure it is giving you what you want.

Rick Rothstein

Different kind of rounding
 
I am apparently missing something in the OP's question, but I would think
ROUNDUP would work directly. Doesn't...

=ROUNDUP(A20,2)

do the same thing as your formula? If not, what am I overlooking?

--
Rick (MVP - Excel)


"Gary''s Student" wrote in message
...
With a value in A20:

=IF(RIGHT(1000*A20,1)=0,A20,ROUNDUP(A20,2))

--
Gary''s Student - gsnu200821


"Sarah_Lund" wrote:

I need help with this one...

If the 3rd digit after the decimal is not a zero, I need to round up the
2nd
digit, otherwise leave the number as is
Examples:
4.240 would be 4.24
4.241 would be 4.25

I'd like to be able to do this in one step/one formula.
Any suggestions??
Thank you,
Sarah




All times are GMT +1. The time now is 02:13 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com