proportion2percentile: Rounds proportions to significant digits both near 0 and 1,...

View source: R/main.R

proportion2percentileR Documentation

Rounds proportions to significant digits both near 0 and 1, then converts to percentiles

Description

Rounds proportions to significant digits both near 0 and 1, then converts to percentiles

Usage

proportion2percentile(
  p,
  digits = 2,
  remove_leading_zero = TRUE,
  add_percent_character = FALSE
)

Arguments

p

probability

digits

rounding digits

remove_leading_zero

If TRUE, remove leading zero

add_percent_character

If TRUE, add percent character

Value

character vector

Examples

proportion2percentile(0.011111)

wjschne/WJSmisc documentation built on June 29, 2023, 8:04 a.m.