summary_to_gt: Convert Bootstrap Summary Tables to gt Objects

View source: R/summary_to_gt.R

summary_to_gtR Documentation

Convert Bootstrap Summary Tables to gt Objects

Description

Converts tables created using boot_summary and censboot_summary to nicely formatted gt tables.

Usage

summary_to_gt(
  summary_table,
  decimals = 3,
  p_threshold = 0.001,
  conf = "95 % CI"
)

Arguments

summary_table

A table created using boot_summary or censboot_summary.

decimals

The number of decimals to print for estimates and confidence intervals. The default is 3.

p_threshold

p-values below this value will be printed as "<p_threshold", e.g. "<0.001". The default is 0.001.

conf

The text at the top of the confidence interval column in the gt table. The default is "95 % CI".

Value

A gt table.

Examples

# Bootstrap summary of a linear model for mtcars:
model <- lm(mpg ~ hp + vs, data = mtcars)
boot_summary(model, R = 99) |> summary_to_gt()

boot.pval documentation built on Sept. 28, 2023, 5:07 p.m.