Use prettyNum()
to format numbers
fmt_pretty(big.mark = ",", ..., scientific = FALSE)
Passed to prettyNum()
.
An object you can pass into number_format()
.
Other format functions:
fmt_percent()
jams$Sales <- c("Sales", 35000,
55500, 20000)
set_number_format(jams, -1, "Sales",
fmt_pretty())
#> Type Price Sales
#> Strawberry 1.90 35,000
#> Raspberry 2.10 55,500
#> Plum 1.80 20,000
#>
#> Column names: Type, Price, Sales