string_switch <- function(field_name, codes) {
if (is.null(codes)) return(NULL)
.call <- list(
quote(`%in%`),
as.name(field_name),
codes
)
as.call(.call)
}
not_string_switch <- function(field_name, codes) {
if (is.null(codes)) return(NULL)
.call <- list(
quote(`%not in%`),
as.name(field_name),
codes
)
as.call(.call)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.