str_wrap: str_wrap

Description Usage Arguments Value Author(s) Examples

View source: R/str_wrap.R

Description

Wraping long string to multiple lines, adapted from yulab.utils

Usage

1
str_wrap(string, width = getOption("width"))

Arguments

string

input string to be wrapped

width

the length characters of each line

Value

a wrapped characters

Author(s)

Zhonghui Gai

Examples

1
2
x <- c("this is a   looooooooong text", "this is a shorter text")
str_wrap(string = x, width = 10)

ZhonghuiGai/gglefse documentation built on Dec. 18, 2021, 8:28 p.m.