str_chop: Chop strings by given length

View source: R/str_chop.R

str_chopR Documentation

Chop strings by given length

Description

str_chop() lets you chop strings into pieces by fixed length.

Usage

str_chop(string, length = 1)

Arguments

string

A string in vector or list format.

length

Length of string pieces

Value

A list.

Examples

x <- paste(letters, collapse = "")
str_chop(x)
str_chop(x, 2)
str_chop(x, 6)

botan/bfun documentation built on June 15, 2022, 8:44 a.m.