R/utils-format-round.R

Defines functions format_round

Documented in format_round

#' Format digits (internal use only)
#'
#' @param x object
#' @param digits number of digits to round to
#' @keywords internal
#' @return a rounded string
format_round <- function(x, digits = 3) {
  format(round(x, digits = digits), nsmall = digits, scientific = FALSE)
}
jasonmoy28/psycModel documentation built on Sept. 6, 2024, 11:45 a.m.