https://github.com/cran/bayestestR
Revision d8462ad2168ad7ee61c0d7e679174e775f01a9be authored by Dominique Makowski on 18 January 2020, 07:10 UTC, committed by cran-robot on 18 January 2020, 07:10 UTC
1 parent 4936034
Raw File
Tip revision: d8462ad2168ad7ee61c0d7e679174e775f01a9be authored by Dominique Makowski on 18 January 2020, 07:10 UTC
version 0.5.0
Tip revision: d8462ad
print.describe_posterior.R
#' @importFrom insight format_table
#' @export
print.describe_posterior <- function(x, digits = 3, ...) {
  if ("data_plot" %in% class(x)) {
    cat(insight::format_table(as.data.frame(x), digits = digits))
  } else {
    insight::print_color("# Description of Posterior Distributions\n\n", "blue")
    if (!is.null(attributes(x)$ci_method) && tolower(attributes(x)$ci_method) == "si") {
      cn <- gsub("^CI", "SI", colnames(x))
      colnames(x) <- cn
    }
    print_data_frame(x, digits = digits)
  }
}
back to top