View source: R/number_to_word.R
It is usually conventional that integers below 10 should be written in words instead of numbers. In RMarkdown, when writing results, the the output of the results, the user can put the numbers in the present function to convert it automatically into text. If the result to display is 2, then number_toword(2) will return "two".
1 | number_to_word(number, cap = FALSE)
|
number |
Integer to convert into word |
cap |
If TRUE, the first letter of the word will be a capital. Default is FALSE |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.