[Python-ideas] Fwd: Re: PEP 485: A Function for testing approximate equality (original) (raw)

Kyle Lahnakoski klahnakoski at mozilla.com
Tue Feb 17 14:21:25 CET 2015


Chris Barker,

If isclose() function is to be part of the standard library I would ask that the rel_tol and abs_tol both accept -log10 scaled values:

Instead of

isclose(a, b, reltol=1e-9, abstol=0.0)

we have

isclose(a, b, reltol=9, abstol=-INF)

rel_tol can be understood in terms of number of significant digits.
abs_tol is understood in terms of fixed decimal digits.

Thanks for noticing the ubiquitous need for such function.

On Thursday, February 5, 2015 at 12:14:25 PM UTC-5, Chris Barker - NOAA Federal wrote: Hi folks, Time for Take 2 (or is that take 200?)

-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://mail.python.org/pipermail/python-ideas/attachments/20150217/ce065771/attachment.html>



More information about the Python-ideas mailing list