number_to_word: Convert a number into an English word

View source: R/numbers.R

number_to_wordR Documentation

Convert a number into an English word

Description

Convert a number into an English word

Usage

number_to_word(x, th = FALSE, cap_first = FALSE)

Arguments

x

The number to change into English

th

Make the word end in 'st', 'nd', 'rd', or 'th'

cap_first

Capitalize the first letter of the resulting word

Value

English text representing the number given

Examples

number_to_word(1)
number_to_word(999999, th = TRUE)
number_to_word(101, cap_first = TRUE)

pbs-assess/gfutilities documentation built on Sept. 18, 2023, 7:57 a.m.