fractions and decimals!

A

AmyTaylor

Hi everyone, hope someone can help with this formulae:

I have numbers in a cell, assume it is A1:

Example: cell in A1 contains: 2.34
I want to show the fraction element of the cell, in this example it
would be 0.3,

if the number was 0.56 then the element would be 0.6 (not 0.5) as I
would want to round to the nearest significant fraction.

Finally, I want to say that if the fraction is at least 15% of the
original figure then round it up

Hope this makes sense !
thanks
Amy xx
 
B

Bernard Liengme

This will display just the first decimal place, rounded:
=ROUND(MOD(A1,1),1)
This seems to satisfy your 15% rule but needs more testing:
=ROUND(MOD(A1,1)+0.05*(MOD(A1,1)>=A1*15%),1)
best wishes
 
A

AmyTaylor

Thank you very much, can you tell me how, using a formula, if I had the
figure 56.7 I could show the 56 portion only.
Then if the .7 was 15% of the 56 then it would round the 56.7 to 57,
otherwise it would stay at 56.

Thanks again.
Amy xx
 
A

AmyTaylor

Thank you very much, can you tell me how, using a formula, if I had the
figure 56.7 I could show the 56 portion only.
Then if the .7 was 15% of the 56 then it would round the 56.7 to 57,
otherwise it would stay at 56.

Thanks again.
Amy xx
 
B

Bernard Liengme

Again you should test:
To get just the integer part us =INT(A10)
(hope there are no neg numbers - if so replace INT by TRUNC)
To apply your rule
=INT(A10)+(MOD(A10,1)>=INT(A10)*15%)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top