[R] How to 'mute' a function (like confint())

Remko Duursma
Tue, 02 Aug 2011 07:30:28 -0000

Dear R-helpers,

I am using confint() within a function, and I want to turn off the message
it prints:

x <- rnorm(100)
y <- x^1.1+rnorm(100)
nlsfit <- nls(y ~ g0*x^g1, start=list(g0=1,g1=1))

> confint(nlsfit)
Waiting for profiling to be done...
        2.5%    97.5%
g0 0.4484198 1.143761
g1 1.0380479 2.370057


I cannot find any way to turn off 'Waiting for. .."

I tried

options(max.print=0)

and even

sink(tempfile())
confint(nlsfit)
sink()

This suppresses the printing of the table, but not the cat()-ing of the
'Waiting for...'.

But it keeps writing this message; is there any way to mute it, for this
function and more generally?


thanks,
Remko


--
View this message in context:
http://r.789695.n4.nabble.com/How-to-mute-a-function-like-confint-tp3711537p3711537.html
Sent from the R help mailing list archive at Nabble.com.