Learn R Programming

wrappedtools (version 0.9.7)

median_cl_boot: Compute confidence interval of median by bootstrapping.

Description

median_cl_boot computes lower and upper confidence limits for the estimated median, based on bootstrapping.

Usage

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

Value

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

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.

Examples

Run this code
# basic usage of median_cl_boot
median_cl_boot(x = mtcars$wt)

Run the code above in your browser using DataLab