Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!us.feeder.erje.net!news.linkpendium.com!news.linkpendium.com!panix!not-for-mail From: Grant Edwards Newsgroups: comp.lang.python Subject: Re: Significant digits in a float? Date: Wed, 30 Apr 2014 18:18:15 +0000 (UTC) Organization: PANIX Public Access Internet and UNIX, NYC Lines: 20 Message-ID: References: <535f0f9f$0$29965$c3e8da3$5496439d@news.astraweb.com> NNTP-Posting-Host: dsl.comtrol.com X-Trace: reader1.panix.com 1398881895 18350 64.122.56.22 (30 Apr 2014 18:18:15 GMT) X-Complaints-To: abuse@panix.com NNTP-Posting-Date: Wed, 30 Apr 2014 18:18:15 +0000 (UTC) User-Agent: slrn/1.0.1 (Linux) Xref: csiph.com comp.lang.python:70785 On 2014-04-29, Roy Smith wrote: >> What reason do you have to think that something recorded to 14 >> decimal places was only intended to have been recorded to 4? > > Because I understand the physical measurement these numbers represent. > Sometimes, Steve, you have to assume that when somebody asks a question, > they actually have asked the question then intended to ask. Sometimes. But the smart money bets against it -- especially when people are asking about floating point. :) It doesn't sound to me like you have enough information to reliably do what you want to do, but parsing the string representation is probably the best way to go. -- Grant Edwards grant.b.edwards Yow! HELLO KITTY gang at terrorizes town, family gmail.com STICKERED to death!