This is the documentation for the development version.
There are no official binaries for it; build it from the source code in git.
Download links on these pages work only after the release.
For the current release, see version 7.0.
FormatMetricPrefix
- FormatMetricPrefix(number, binary, precision): String
-
Convert numeric value to human-readable form with metric prefix.
Table 1. Parameters number
Number
Number to format.
binary
Boolean
Optional argument. Set to true to use binary multipliers (Ki, Mi, etc.). Default value is false.
precision
Unsigned Integer
Optional argument with rounding precision. Acceptable values are from 0 to 20. Default value is 2.
ReturnString containing the value converted to human-readable form with metric prefix.
>>> FormatMetricPrefix(5000) 5.00 k >>> FormatMetricPrefix(5000, true) 4.88 Ki >>> FormatMetricPrefix(-1234567.89, false, 0) -1 M >>> FormatMetricPrefix(-1234567.89, false, 10) -1.2345678900 M