collapse: Collapse vector to string.

View source: R/collapse.R

collapseR Documentation

Collapse vector to string.

Description

A simple wrapper for paste(x, collapse).

Usage

collapse(x, sep = ",")

Arguments

x

[vector]
Vector to collapse.

sep

[character(1)]
Passed to collapse in paste. Default is “,”.

Value

[character(1)].

Examples

collapse(c("foo", "bar"))
collapse(c("foo", "bar"), sep = ";")

BBmisc documentation built on Sept. 29, 2022, 5:12 p.m.

Related to collapse in BBmisc...