collapse: Collapse a series of strings

Description Usage Arguments Details Value Examples

View source: R/AllFunctions.R View source: R/string_functions.R

Description

Collapse a series of strings

Usage

1
collapse(..., sep = "")

Arguments

...

A vector, or vectors of strings

sep

A delimeter on which two collapse strings

Details

A wrapper for paste0(..., collapse = <option>). Built to be more clear than paste0() when collapsing strings, and to avoid the issue of no partial string match in the paste() functions for the colllapse option.

Value

A single string of collapsed input

Examples

1
2
3
4
collapse(c("species", "yellow"), c("species", "yellow"), sep = ' ')
[1] "speciesspecies yellowyellow"
collapse(c("species", "yellow"))
[1] "speciesyellow"

andrewjameshaynes/helpeR documentation built on May 28, 2019, 2:44 p.m.