f | |
| :mod:`fpformat` --- Floating point conversions |
| ============================================== |
| |
| .. module:: fpformat |
| :synopsis: General floating point formatting functions. |
n | :deprecated: |
| |
| .. deprecated:: 2.6 |
| The :mod:`fpformat` module has been removed in Python 3.0. |
| |
| .. sectionauthor:: Moshe Zadka <moshez@zadka.site.co.il> |
| |
| |
| The :mod:`fpformat` module defines functions for dealing with floating point |
| numbers representations in 100% pure Python. |
| |
| .. note:: |
| |
t | This module is unneeded: everything here could be done via the ``%`` string |
t | This module is unnecessary: everything here can be done using the ``%`` string |
| interpolation operator. |
| interpolation operator described in the :ref:`string-formatting` section. |
| |
| The :mod:`fpformat` module defines the following functions and an exception: |
| |
| |
| .. function:: fix(x, digs) |
| |
| Format *x* as ``[-]ddd.ddd`` with *digs* digits after the point and at least one |
| digit before. If ``digs <= 0``, the decimal point is suppressed. |