Suppress one command's output in R -
i'm looking suppress output of one command (in case, apply
function).
is possible without using sink()
? i've found described solution below, in 1 line if possible.
it isn't clear why want without sink
, can wrap commands in invisible()
function , suppress output. instance:
1:10 # prints output invisible(1:10) # hides
otherwise, can combine things 1 line semicolon , parentheses:
{ sink("/dev/null"); ....; sink(); }
Comments
Post a Comment