R/hush.R

Defines functions hush

Documented in hush

#' Execute code silently
#'
#' @keywords internal
hush <- function(code) {
    void <- utils::capture.output({
        out <- invisible(
            suppressMessages(
                suppressWarnings(
                    tryCatch(code, error = function(e) NULL))
            )
        )
    })
    return(out)
}

Try the modelsummary package in your browser

Any scripts or data that you put into this service are public.

modelsummary documentation built on Oct. 15, 2023, 5:06 p.m.