*! version 1.1.0 7.October.2017

Title

cmatch- Tabulation of matched pairs in 1:1 case control study by exposure status

Syntax

cmatch Y xvar group [if] [in]

where:

Y: The name of the binary indicator (0: control, 1: case) of the case and control status.

xvar: The name of the exposure categorical variable.

group: The name of the variable which identifies the matched 1:1 pair.

Description

Matched case-control studies are a classical Epidemiology study design. Case-control study designs are used
to estimate the relative risk for a disease from a specific risk factor. The estimate is the odds ratio, which is
a good estimate of the relative risk especially when the disease is rare. cmatch tabulates the number of
matched pairs by c levels of an exposure variable. cmatch forms a c x c table of matched pairs
by the exposure status of the case and the exposure status of the control. The data must be in the form of individual records.

Example

webuse lowbirth2
cmatch low smoke pairid
clogit low smoke, group(pairid) or vsquish

. webuse lowbirth2
(Applied Logistic Regression, Hosmer & Lemeshow)

. cmatch low smoke pairid
1:1 matched pairs (case-control) by levels of the exposure variable: smoke

| Cases
Controls | 0 1 | Total
-----------+----------------------+----------
0 | 18 22 | 40
1 | 8 8 | 16
-----------+----------------------+----------
Total | 26 30 | 56

Matched pairs by smoke: 26

. clogit low smoke, group(pairid) or vsquish
Conditional (fixed-effects) logistic regression
Number of obs = 112
LR chi2(1) = 6.79
Prob > chi2 = 0.0091
Log likelihood = -35.419282 Pseudo R2 = 0.0875

------------------------------------------------------------------------------
low | Odds Ratio Std. Err. z P>|z| [95% Conf. Interval]
-------------+----------------------------------------------------------------
smoke | 2.75 1.135369 2.45 0.014 1.224347 6.176763
------------------------------------------------------------------------------

Remarks

Remember: Y must be a binary indicator variable coded (0, 1); xvar must be a categorical
variable and, group is the variable that identifies the 1:1 matched pair.

References

Hosmer DW, Lemeshow S (2000) Applied logistic regression (Wiley series in probability and statistics). Wiley, New York

Authorship and developer

Authorship: EPM304-London School of Hygiene and Tropical Medicine

Developer: Miguel Angel Luque-Fernandez

Department of Epidemiology and Population Health, London School of Hygiene and Tropical Medicine, London, U.K.

E-mail:miguel-angel.luque@lshtm.ac.uk

Also see

Online: clogit