doubleQuoteText: Add double quotes to strings.

View source: R/toolbox.R

doubleQuoteTextR Documentation

Add double quotes to strings.

Description

Add double quotes to strings.

Usage

doubleQuoteText(
  x,
  char_only = TRUE,
  excluded_chars = c("NULL"),
  null_or_na_as_NULL = TRUE
)

Arguments

x

A string.

char_only

TRUE/FALSE, if TRUE, adds quotes only if is.character(x) is TRUE.

excluded_chars

A character vector, will not add quotes if a value is in excluded_chars.

null_or_na_as_NULL

TRUE/FALSE, if TRUE, NULL and NA values are replaced with the string "NULL".

Value

A string, with double quotes added.

Examples

doubleQuoteText("Sample quotes.")

toolbox documentation built on Sept. 22, 2022, 1:09 a.m.