Path: csiph.com!v102.xanadu-bbs.net!xanadu-bbs.net!feeder.erje.net!eu.feeder.erje.net!xlned.com!feeder3.xlned.com!newsfeed.xs4all.nl!newsfeed1a.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.038 X-Spam-Evidence: '*H*': 0.92; '*S*': 0.00; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'coordinates': 0.16; 'given,': 0.16; 'imo.': 0.16; 'losing': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'roy': 0.16; 'wrote:': 0.18; 'trying': 0.19; 'figures': 0.19; 'header:User-Agent:1': 0.23; "i've": 0.25; 'values': 0.27; 'header:X-Complaints-To:1': 0.27; 'header:In-Reply-To:1': 0.27; 'point': 0.28; 'appear': 0.29; 'chris': 0.29; "i'm": 0.30; 'but': 0.35; 'appearance': 0.36; 'false': 0.36; 'height': 0.36; 'subject:?': 0.36; 'url:org': 0.36; 'to:addr:python-list': 0.38; 'pm,': 0.38; 'reported': 0.39; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'then,': 0.60; 'first': 0.61; 'story': 0.63; 'chance': 0.65; 'within': 0.65; 'smith': 0.68; '10%': 0.74; 'gone.': 0.84; 'resulted': 0.84; 'ten,': 0.84 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: Ned Batchelder Subject: Re: Significant digits in a float? Date: Tue, 29 Apr 2014 12:47:22 -0400 References: <535f0f9f$0$29965$c3e8da3$5496439d@news.astraweb.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Gmane-NNTP-Posting-Host: 18.189.27.191 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:24.0) Gecko/20100101 Thunderbird/24.4.0 In-Reply-To: X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 22 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1398790058 news.xs4all.nl 2869 [2001:888:2000:d::a6]:34463 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:70720 On 4/29/14 12:30 PM, Chris Angelico wrote: > On Tue, Apr 29, 2014 at 11:38 PM, Roy Smith wrote: >> I'm trying to intuit, from the values I've been given, which coordinates >> are likely to be accurate to within a few miles. I'm willing to accept >> a few false negatives. If the number is float("38"), I'm willing to >> accept that it might actually be float("38.0000"), and I might be >> throwing out a good data point that I don't need to. > > You have one chance in ten, repeatably, of losing a digit. That is, > roughly 10% of your four-decimal figures will appear to be > three-decimal, and 1% of them will appear to be two-decimal, and so > on. Is that "a few" false negatives? It feels like a lot IMO. But > then, there's no alternative - the information's already gone. > Reminds me of the story that the first survey of Mt. Everest resulted in a height of exactly 29,000 feet, but to avoid the appearance of an estimate, they reported it as 29,002: http://www.jstor.org/stable/2684102 -- Ned Batchelder, http://nedbatchelder.com