| capture.output2 {toscutil} | R Documentation |
Capture output from a command
Description
Like classic capture.output(), but with additional arguments collapse and trim.
Usage
capture.output2(..., collapse = "\n", trim = FALSE)
Arguments
... |
Arguments passed on to |
collapse |
If |
trim |
If |
Value
If collapse is TRUE or "\n", a character vector of length 1. Else, a character vector of length n, where n corresponds to the number of lines outputted by the expression passed to capture.output().
See Also
Examples
x <- capture.output2(str(list(a = 1, b = 2, c = 1:3)))
cat2(x)
[Package toscutil version 2.8.0 Index]