floatformat
Display a float to a specified number of decimal places.
def floatformat(
text: any,
arg: int|str = -1
) - > string
Display a float to a specified number of decimal places.
Parameters
| Name | Type | Description |
|---|---|---|
| text | any | The numeric value or string representation of a number to be formatted. |
| arg | `int | str` = -1 |
Returns
| Type | Description |
|---|---|
string | The formatted numeric string, localized or unlocalized based on arguments, or an empty string if the input is invalid. |