Convert a small number to a text representation

num_to_text(x, capitalize = FALSE)

Arguments

x

An integer to convert to text.

capitalize

Boolean - whether or not to capitalize text

Value

A character string.

Examples

num_to_text(5, capitalize = TRUE)
#> [1] "Five"
num_to_text(23, capitalize = FALSE)
#> [1] "twenty-three"