Skip to contents

Simple wrapper for concatenating strings

Usage

collapse(..., sep = "")

Arguments

...

one or more R objects, to be converted to character vectors.

sep

a character string to separate the terms. Not NA_character_.

Value

A character vector of concatenated values. See base::paste for more details.

Examples

collapse(1:10)
#> [1] "12345678910"
collapse(list("a", b = 1:2))
#> [1] "a12"
collapse(quick_dfl(a = 1:3, b = 4:6), sep = "-")
#> [1] "1-2-3-4-5-6"