summary.ci: Summarize confidence intervals

View source: R/summary.ci.R

summary.ciR Documentation

Summarize confidence intervals

Description

Summarize confidence intervals

Usage

## S3 method for class 'ci'
summary(object, format = "[u;l]", se = FALSE, print = TRUE, ...)

Arguments

object

Object of class ci containing point estimates and the corresponding confidence intervals

format

A string which indicates the format used for confidence intervals. The string is passed to formatCI with two arguments: the lower and the upper limit. For example '(l;u)' yields confidence intervals with round parenthesis in which the upper and the lower limits are separated by semicolon.

se

If TRUE add standard error.

print

Logical: if FALSE do not actually print confidence intervals but just return them invisibly.

...

used to control formatting of numbers

Details

This format of the confidence intervals is user-manipulable.

Value

Formatted confidence intervals

Author(s)

Thomas A. Gerds <tag@biostat.ku.dk>

See Also

ci plot.ci format.ci

Examples

library(lava)
m <- lvm(Y~X)
m <- categorical(m,Y~X,K=4)
set.seed(4)
d <- sim(m,24)
ci.mean(Y~X,data=d)
x <- summary(ci.mean(Y~X,data=d),digits=2)
x
x <- summary(ci.mean(Y~X,data=d),format="(u,l)",digits=2)
x <- summary(ci.mean(Y~X,data=d),format="(u,l)",digits=1,se=TRUE)
x <- summary(ci.mean(Y~X,data=d),format="(u,l)",digits=1,handler="format")
x <- summary(ci.mean(Y~X,data=d),format="(u,l)",digits=1,handler="prettyNum")

Publish documentation built on Jan. 18, 2023, 1:08 a.m.