Same as cat(sprintf(fmt, ...))
Arguments
- fmt
A character vector of format strings, each of up to 8192 bytes.
- ...
Up to 100 values to be passed into
fmt. Only logical, integer, real and character vectors are supported, but some coercion will be done: see the Details section ofbase::sprintf().- file
A connection, or a character string naming the file to print to. If
""(the default),cat2prints to the standard output connection, the console unless redirected by sink.- append
logical. Only used if the argument
fileis the name of file (and not a connection or"|cmd"). IfTRUEoutput will be appended tofile; otherwise, it will overwrite the contents offile.- fill
a logical or (positive) numeric controlling how the output is broken into successive lines. If
FALSE(default), only newlines created explicitly by"\n"are printed. Otherwise, the output is broken into lines with print width equal to the optionwidthiffillisTRUE, or the value offillif this is numeric. Linefeeds are only inserted between elements, strings wider thanfillare not wrapped. Non-positivefillvalues are ignored, with a warning.- labels
character vector of labels for the lines printed. Ignored if
fillisFALSE.