ci.se: ci to se

ci.seR Documentation

ci to se

Description

compute standard error from confidence interval
we recommend checking the computations by using result = "diff". see below.
computations are based on t-distribution, not z

Usage

ci.se(est, cil, ciu, n, k, result = c("ciu", "cil", "avg", "diff", "marge"))

Arguments

est

the point estimate (e.g., a regression coefficient, a mean)

cil

the lower bound of the confidence interval

ciu

the upper bound of the confidence interval

n

the sample size

k

the total number of predictors. for converting the ci associated with a raw mean, enter k = 0.

result

select one of:

  • "ciu" will compute se based on upper bound of ci (this is the default if unspecified)

  • "cil" will compute se based on lower bound of ci

  • "avg" will compute se from both ciu and cil and take the average

  • "diff" will give the difference between the se computed using ciu and using cil. for transformed point estimate, see sediff() function.

Examples

# e.g., regression b=.156, 95CI [.10, .225], n=166, 3 total predictors
ci.se(.156, .10, .225, 166, 3)


phoebehlam/michaela documentation built on Oct. 23, 2024, 4:10 p.m.