Formats numbers in scientific format.

num_scientific(x, format = c("e", "E"), ...)

Arguments

x

a numeric vector.

format

format type passed to formatC().

...

additional parameter passed to formattable().

See also

Other numeric vectors: num_accounting(), num_comma(), num_currency(), num_digits(), num_percent()

Examples

num_scientific(1250000)
#> [1] 1.2500e+06
num_scientific(1253421, digits = 8)
#> [1] 1.25342100e+06
num_scientific(1253421, digits = 8, format = "E")
#> [1] 1.25342100E+06