sample_str <- function(values, size, global, use_openssl) {
values[random_integer(length(values), size, global, use_openssl)]
}
sample_str_weighted <- function(values, size, prob, global, use_openssl) {
values[random_integer_weighted(prob, size, global, use_openssl)]
}
`%||%` <- function(a, b) { # nolint
if (is.null(a)) b else a
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.