Generates random character string composed of lower and upper case letters with an option to include digits.
util_rand_str(characters = 8L, digits = FALSE, ext = NULL)
characters | Integer. Number of characters. |
---|---|
digits | Logical. Use digits. |
ext | Character string. Optional file extension. |
To ensure that the character string generated
is a valid R
variable name,
the first character will always be
a lower case or upper case letter
when digits = TRUE
.
Ivan Jacob Agaloos Pesigan
util_rand_str(characters = 8L, ext = "R")#> [1] "qZvEafHY.R"