add_prefix: Add a prefix to each word

Description Usage Arguments Value Examples

View source: R/RcppExports.R

Description

Add a custom prefix to each word of a a line to create different spaces. Code in C++ (efficient).

Usage

1
add_prefix(texts, prefix)

Arguments

texts

a character containing the original text

prefix

unit character containing the prefix to add (length == 1) or character with same length than texts

Value

character with prefixed words.

Examples

1
add_prefix(c("this is a test", "this is another    test"), "#")

fastrtext documentation built on Oct. 30, 2019, 11:32 a.m.