Returns approximate variance (i.e., squared standard error) of point estimate given either the upper or lower limit (ci.lim
) of a Wald-type confidence interval. If degrees of freedom (df
) are not provided, it is assumed that the confidence interval uses a z-distribution approximation. If degrees of freedom are provided, it is assumed that the confidence interval uses a t-distribution approximation.
ci_to_var(est, ci.lim, ci.level = 0.95, df = NA)
Point estimate
Lower or upper confidence interval limit
Confidence interval level as a proportion (e.g., 0.95)
Degrees of freedom
The estimate and confidence interval must be provided on a scale such that the confidence interval is symmetric. For example, if the point estimate is a relative risk, then the estimate and confidence interval should be provided on the log-relative risk scale.