mean_cl_boot: Compute confidence interval of mean by bootstrapping.

View source: R/descriptives.R

mean_cl_bootR Documentation

Compute confidence interval of mean by bootstrapping.

Description

mean_cl_boot computes lower and upper confidence limits for the estimated mean, based on bootstrapping.

Usage

mean_cl_boot(
  x,
  conf = 0.95,
  type = "basic",
  nrepl = 10^3,
  round = FALSE,
  roundDig = 2
)

Arguments

x

Data for computation.

conf

confidence interval with default 95%.

type

type for function boot.ci.

nrepl

number of bootstrap replications, defaults to 1000.

round

logical, applies roundR function to results. Output is character.

roundDig

Number of relevant digits for function roundR.

Value

A tibble with one row and three columns: Mean, CIlow, CIhigh.

Examples

# basic usage of mean_cl_boot
mean_cl_boot(x = mtcars$wt)

wrappedtools documentation built on June 8, 2025, 10:58 a.m.