examples/helpers-rapply.R

# Some model function.
my_model <- function() {
  alpha0 <- mean(1:10)
  alpha1 <- 600000
}

# Replace format of numbers using `formatC` function.
h_rapply(
  x = body(my_model),
  fun = formatC,
  classes = c("integer", "numeric"),
  digits = 3,
  format = "E"
)
Roche/crmPack documentation built on July 16, 2024, 2:15 a.m.