[R] Retrievable results in a procedure
@@r@h@go@lee @ending from gm@il@com
Tue Dec 25 16:10:41 CET 2018
I'm a bit confused about what you actually want, but I think invisible()
might be the answer.
Note that there's already a base function try() so that's not a great name
for test functions.
On Tue, Dec 25, 2018 at 8:47 AM Steven Yen <styen using ntu.edu.tw> wrote:
> I would like to suppressed printing of retrievable results in a
> procedure and to print only when retrieved.
> In line 10 below I call procedure "try" and get matrices A,B,C all
> printed upon a call to the procedure. I get around this unwanted
> printing by calling with v<-try(A,B) as in line 11.
> Any way to suppress printing of the retrievable results listed in the
> structure command? Thank you, and Merry Christmas to all.
> cat("\nC:\n"); print(C)
> try(A,B) # line 10
> v<-try(A,B) # line 11
> styen using ntu.edu.tw (S.T. Yen)
> [[alternative HTML version deleted]]
> R-help using r-project.org mailing list -- To UNSUBSCRIBE and more, see
> PLEASE do read the posting guide
> and provide commented, minimal, self-contained, reproducible code.
Sarah Goslee (she/her)
[[alternative HTML version deleted]]
More information about the R-help