
Last chance! 50% off unlimited learning
Sale ends in
collapse
) into input character strings.
The main intention of this
function is to prepare long strings for printing, so the output
is not wider than width
.
strbreak(x, width=getOption("width"), exdent=2, collapse="\n")
strwrap
, substring
longString = paste(rep(LETTERS, 10), collapse="", sep="")
cat(strbreak(longString))
Run the code above in your browser using DataLab