Description Usage Arguments Value Author(s) Examples
View source: R/force_decimals.R
Force printing a specified number of decimals for a number
1 | force_decimals(x, decimals = 2)
|
x |
the numeric values to be printed |
decimals |
how many decimals are to be printed. Defaults to 2. |
The number in the required format
Martin Papenberg martin.papenberg@hhu.de
1 2 | force_decimals(c(1.23456, 0.873, 2.3456))
force_decimals(c(1.23456, 0.873, 2.3456), 3)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.