numfmt --to=si 1500000

Category: Data Science & Analysis

numfmt --to=si 1500000

Format 1500000 with SI unit suffixes

numfmt converts numbers between human and machine formats. The --to=si flag prints 1500000 as 1.5M using SI (powers of 1000) suffixes. The iec variant uses powers of 1024 and is common for memory sizes. Feed it file sizes from du or stat to make them readable, and add --padding to right-align a column of values.
Looking for more? Search all 7,657 commands — works offline, in English or Spanish, and fixes typos.