#' Convert a List to A Sentence Form
#' Vectors of 1, 2 and 3 letters become 'A', 'A and B', 'A, B and C'.
#' @noRd
.vector_to_sentence <- function(vector) {
if (length(vector) > 1) {
last <- vector[length(vector)]
not_last <- vector[-length(vector)]
sentence <- paste(paste(not_last, collapse = ", "), "and", last)
return(sentence)
}
vector
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.