+ Reply to Thread
Results 1 to 6 of 6

How to calculate/properly display significant figures ending in 0

  1. #1
    A Zaffiro
    Guest

    How to calculate/properly display significant figures ending in 0

    To report numbers in significant figures, Excel Help gives the following
    formula and states that it is valid for numbers above zero:

    =ROUND(B18,2-LEN(INT(B18))), where B18 is the number to round, and 2 is the
    the number of significant figures desired.

    In fact, it only works for numbers above 1, and if the number format is set
    to 'general'

    The formula works, but here's the problem: If the result ends in zero (e.g.
    2.0), Excel only displays the last non-zero integer (e.g. 2). Since the last
    zero is significant, this is a problem.


  2. #2
    Forum Expert swatsp0p's Avatar
    Join Date
    10-07-2004
    Location
    Kentucky, USA
    MS-Off Ver
    Excel 2010
    Posts
    1,545
    If you format the cell with the formula as Number, you can set the number of decimal places to display. If you set it to 1, your listed formula will show 2.0 for a value of 2.015 (and will show 2000.0 for a value of 2015.15)

    HTH

    Bruce
    Bruce
    The older I get, the better I used to be.
    USA

  3. #3
    Bob Phillips
    Guest

    Re: How to calculate/properly display significant figures ending in 0

    How about this

    =TEXT(B18,"##0"&IF(2-INTO(B18)>0,"."&REPT("0",2-INT(B18)),""))

    --

    HTH

    RP
    (remove nothere from the email address if mailing direct)


    "A Zaffiro" <A Zaffiro@discussions.microsoft.com> wrote in message
    news:10B8F37A-B607-4B6F-92B9-4EE4C288AAAA@microsoft.com...
    > To report numbers in significant figures, Excel Help gives the following
    > formula and states that it is valid for numbers above zero:
    >
    > =ROUND(B18,2-LEN(INT(B18))), where B18 is the number to round, and 2 is

    the
    > the number of significant figures desired.
    >
    > In fact, it only works for numbers above 1, and if the number format is

    set
    > to 'general'
    >
    > The formula works, but here's the problem: If the result ends in zero

    (e.g.
    > 2.0), Excel only displays the last non-zero integer (e.g. 2). Since the

    last
    > zero is significant, this is a problem.
    >




  4. #4
    A Zaffiro
    Guest

    Re: How to calculate/properly display significant figures ending i

    Thanks. Inventive solution. That seems to work for numbers between 1 and
    100. FYI: for numbers less than 1, I came up with:

    =ROUND(B3,LEN(INT(1/B3))+1), where B3 is the decimal number to round, and
    '1' is one less than the number of significant figures desired.

    This formula suffers from the same zero problem. I will attemp to resolve
    once I better understand the technique that you used to solve the zero
    problem for numbers greater than 1.

    "Bob Phillips" wrote:

    > How about this
    >
    > =TEXT(B18,"##0"&IF(2-INTO(B18)>0,"."&REPT("0",2-INT(B18)),""))
    >
    > --
    >
    > HTH
    >
    > RP
    > (remove nothere from the email address if mailing direct)
    >
    >
    > "A Zaffiro" <A Zaffiro@discussions.microsoft.com> wrote in message
    > news:10B8F37A-B607-4B6F-92B9-4EE4C288AAAA@microsoft.com...
    > > To report numbers in significant figures, Excel Help gives the following
    > > formula and states that it is valid for numbers above zero:
    > >
    > > =ROUND(B18,2-LEN(INT(B18))), where B18 is the number to round, and 2 is

    > the
    > > the number of significant figures desired.
    > >
    > > In fact, it only works for numbers above 1, and if the number format is

    > set
    > > to 'general'
    > >
    > > The formula works, but here's the problem: If the result ends in zero

    > (e.g.
    > > 2.0), Excel only displays the last non-zero integer (e.g. 2). Since the

    > last
    > > zero is significant, this is a problem.
    > >

    >
    >
    >


  5. #5
    Jerry W. Lewis
    Guest

    Re: How to calculate/properly display significant figures ending in 0

    A more general formula for rounding to a specified number of significant
    figures is given in
    http://groups-beta.google.com/group/...244c8f41e91025
    but that does not address the question of general display of trailing zeros.

    Jerry

    A Zaffiro wrote:

    > To report numbers in significant figures, Excel Help gives the following
    > formula and states that it is valid for numbers above zero:
    >
    > =ROUND(B18,2-LEN(INT(B18))), where B18 is the number to round, and 2 is the
    > the number of significant figures desired.
    >
    > In fact, it only works for numbers above 1, and if the number format is set
    > to 'general'
    >
    > The formula works, but here's the problem: If the result ends in zero (e.g.
    > 2.0), Excel only displays the last non-zero integer (e.g. 2). Since the last
    > zero is significant, this is a problem.



  6. #6
    A Zaffiro
    Guest

    Re: How to calculate/properly display significant figures ending i

    Thanks Jerry. I used that plus some of Bob Phillip's ideas to create a
    formula that solves the trailing zero display problem for 2 significant
    figures and works for any number above zero including decimals. It gets
    rather involved to write a general fomula that allows the number of sig fig's
    to vary beyond 2. I'll share the formula after I have a chance to polish and
    test thoroughly.

    Alan Zaffiro

    "Jerry W. Lewis" wrote:

    > A more general formula for rounding to a specified number of significant
    > figures is given in
    > http://groups-beta.google.com/group/...244c8f41e91025
    > but that does not address the question of general display of trailing zeros.
    >
    > Jerry
    >
    > A Zaffiro wrote:
    >
    > > To report numbers in significant figures, Excel Help gives the following
    > > formula and states that it is valid for numbers above zero:
    > >
    > > =ROUND(B18,2-LEN(INT(B18))), where B18 is the number to round, and 2 is the
    > > the number of significant figures desired.
    > >
    > > In fact, it only works for numbers above 1, and if the number format is set
    > > to 'general'
    > >
    > > The formula works, but here's the problem: If the result ends in zero (e.g.
    > > 2.0), Excel only displays the last non-zero integer (e.g. 2). Since the last
    > > zero is significant, this is a problem.

    >
    >


+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Bookmarks

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