Skip to contents

[Stable]

Create Formatting Function for a single extreme value.

Usage

format_extreme_values(digits = 2L)

Arguments

digits

(integer)
number of decimal places to display.

Value

An rtables formatting function that uses threshold digits to return a formatted extreme value.

Examples

format_fun <- format_extreme_values(2L)
format_fun(x = 0.127)
#> [1] "0.13"
format_fun(x = Inf)
#> [1] ">999.99"
format_fun(x = 0)
#> [1] "0.00"
format_fun(x = 0.009)
#> [1] "<0.01"