R/report_p.R

Defines functions report_p

Documented in report_p

#' Report pvals in RMarkdown
#' @export

report_p <- function(x){
  return(ifelse(x<0.001,
                "< .001",
                paste0("= ",round(x,3),1)
                # APAstyler is now deprecated
                #paste0("= ",APAstyler::snip(round(x,3),1))
                #scales::pvalue(x,add_p = TRUE),1)))
                #paste0("= ",as.character(round(x,3)))
  ))
}
thealk/thear documentation built on April 28, 2022, 10:29 p.m.