Message 104336 - Python tracker (original) (raw)
Too late for 2.7, but I would like this to hit 3.2. Some calculators have engineering format as an output option and it would be good for Python.
This issue is being discussed in python-list in thread "Engineering numerical format...". The OP (or someone) posted an Engineer(float) class with a .format method that does what he would like. Participants have been invited by Mark to comment here.
It was noted that Decimal has a .to-engineering-string method, but it follows the standard at page 20 of speleotrove.com/decimal/decarith.pdf which is different from what is being asked for.