compute_stats: Compute generic statistics over time.

View source: R/outfun_core.R

compute_statsR Documentation

Compute generic statistics over time.

Description

Compute generic statistics over time.

Usage

compute_stats(
  x,
  variable,
  strata = get_default_strata(),
  stats = c("p5", "median", "p95")
)

Arguments

x

data frame

variable

variable(s) used to compute the statistics, character vector.

strata

named vector with the strata to use, default is c(SCENARIO="all", ARM="all").

stats

character vector of statistics to compute. Supported: "median", "mean", or percentiles like "p5", "p95", "p2.5", "p97.5".

Value

a summary table in long format


campsis documentation built on Aug. 5, 2026, 9:07 a.m.