Skip to contents

Can be used to provide format functions for labels in ggpltos

Usage

format_sprintf(fmt)

Arguments

fmt

sprintf formatting string. see sprintf()

Value

function formatting x with sprintf

Examples

# add one leading zeroes for 1 digits numbers
add_leading_zeroes <- format_sprintf("%02d")
add_leading_zeroes(1:10)
#>  [1] "01" "02" "03" "04" "05" "06" "07" "08" "09" "10"