*! version 2.0 08jan2024

epitable2 -- Create a composite table for a set of multivariable models

Syntax

Create a composite table after running a set of multivariable models through the collect prefix

epitable2 varname [, options]

options

dp(#) set coeff. & conf. int. to # decimal places; default is dp(2)

cilimiter(strings:string) conf. int. separator; default is cilimiter("-")

title(strings:string) Add a title to your table

notes(strings:string) Add note(s) to your table, mutliple notes need to be enclosed in double-quotes

include include all covariates in the table; default is to show varname only

long set table layout as long; default is wide

export exports to a currently open putdocx document, or opens and exports to a new putdocx document

showp display all p-values in the table; default is to only show trend p-values

export does not save the document, allowing you to continue adding to it.

Description

epitable2 creates a composite table with regression coefficients and 95% confidence intervals after running a set of multivariable models. Each multivariable model that you want included must be collected with the collect prefix.
All models must be collected into the same collection before this command can be run. The collection must be the current collection.

This table is commonly referred to as Table 2 in epidemiological studies. The layout is pre-defined and uses shorter syntax, allowing for faster table generation than would be possible if the user set the table up themselves using collect
commands.

Examples

Setup

. webuse nhanes2

. collect clear

Create a table comparing coefficients for a continuous covariate

. collect: logistic diabetes iron

. collect: logistic diabetes iron age i.sex

. collect: logistic diabetes iron age i.sex bmi i.highbp

. epitable2 iron

Setup

. webuse nhanes2

. collect clear

. xtile iron4c = iron, nq(4)

Create a table comparing individual factors for a factor covariate (usually only has 4 factors)

. collect: logistic diabetes i.iron4c

. collect: logistic diabetes i.iron4c age i.sex

. collect: logistic diabetes i.iron4c age i.sex bmi i.highbp

. epitable2 i.iron4c

Notes

While this command has been designed to work with various regression modelling commands, it has only been tested by the author on regress and logistic. It has not been extensively tested. If you encounter errors with other
commands, please forward them through to the author.

Author

Laura C Whiting

IT Support

Survey Design and Analysis Services

Canberra, Australia

support@surveydesign.com.au

This package was developed with the assistance and direction of:

Zumin Shi

Human Nutrition Department, College of Health Sciences, QU Health

Qatar University

Doha, Qatar