Documentation

13A.24 Demographics (“Table 1”)

The demographics kind combines continuous summaries and categorical counts in a conventional baseline table. It normally needs one row per subject, so repeated-record datasets should use item-specific distinct = ["ID"] after confirming the baseline values are consistent.

Six table kinds and their questions

Numeric variables with more than --table-max-levels unique values, default five, are classified continuous; other variables are categorical. --table-continuous and --table-categorical override detection. This is important for coded sex, race, stage, or treatment variables stored as numbers.

The frozen baseline table explicitly marks AGE, WT, and BMI continuous and SEX and SITE categorical. It groups by ARM and includes Overall. The deliberately confounded SITE/ARM pattern demonstrates why a descriptive table can reveal design structure but cannot explain its cause.

Continuous defaults or requested combined statistics can include mean (SD) and median [min, max]. Categorical percentages use nonmissing values within the variable and group; missing values receive a separate row. Group headings include N, which should reconcile with subject allocation.

Baseline selection deserves explicit rules. If the source has screening, baseline, and post-baseline covariate rows, the first record per ID may not be baseline. Prepare or filter the correct record before distinct. Time-varying laboratory values should not be collapsed into a baseline table without a documented visit rule.

Tables for blinded or randomized studies may require arm ordering, masking, and small-cell policies beyond custom. Apply project standards to the exported CSV rather than implying that a convenient descriptive table is submission-ready automatically.

Common mistakes

  • Counting observation records instead of subjects.
  • Letting a numeric category be treated as continuous.
  • Comparing percentages with different missing denominators.
  • Treating imbalance as proof of bias or causality.

Checklist

  • Reduce to the intended baseline grain.
  • Force ambiguous variable types.
  • Reconcile group and overall N.
  • Inspect missing rows and percentage denominators.
  • Describe patterns without causal overclaiming.

Further reading

See distinct, missingness, frequency tables, and worked tables.