Conditional logistic regression
Conditional logistic regression is an extension of logistic regression that allows one to account for stratification and matching.[src] Its main field of application is observational studies and in particular epidemiology.[src] It was devised in 1978 by Norman Breslow, Nicholas Day, Katherine Halvorsen, Ross L.[src] Prentice and C.[src] Sabai.[src] It is the most flexible and general procedure for matched data.[src]
Conditional logistic regression is an extension of logistic regression that allows one to account for stratification and matching.[src] Its main field of application is observational studies and in particular epidemiology.[src] It was devised in 1978 by Norman Breslow, Nicholas Day, Katherine Halvorsen, Ross L.[src] Prentice and C.[src] Sabai.[src] It is the most flexible and general procedure for matched data.[src] ==Background== Observational studies use stratification or matching as a way to control for confounding.[src] Logistic regression can account for stratification by having a different constant term for each stratum.[src] Let us denote Y_{i\ell}\in\{0,1\} the label (e.g.[src] case status) of the \ell th observation of the i th stratum and X_{i\ell}\in\mathbb{R}^p the values of the corresponding predictors.[src] We then take the likelihood of one observation to be \mathbb{P}(Y_{i\ell}=1|X_{i\ell})=\frac{\exp(\alpha_i + \boldsymbol\beta^\top X_{i\ell})}{1+\exp(\alpha_i + \boldsymbol\beta^\top X_{i\ell})} where \alpha_i is the constant term for the i th stratum.[src] The parameters in this model can be estimated using maximum likelihood estimation.[src] For example, consider estimating the impact of exercise on the risk of cardiovascular disease.[src] If people who exercise more are younger, have better access to healthcare, or have other differences that improve their health, then a logistic regression of cardiovascular disease incidence on minutes spent exercising may overestimate the impact of exercise on health.[src] To address this, we can group people based on demographic characteristics like age and zip code of their home residence.[src] Each stratum i is a group of people with similar demographics.[src] The vector X_{i\ell} contains information about the variable of interest (in this case, minutes spent exercising) for individual \ell in stratum i .[src] The value \alpha_i is the impact of demographics on cardiovascular disease incidence Y_{i\ell} , which is assumed to be the same for all people in the stratum.[src] The vector \boldsymbol\beta (which, in this example, is just a scalar) is the quantity of interest --- the impact of exercise on cardiovascular disease.[src] We can also include control variables within X_{i\ell} .[src] ==Motivation== Logistic regression as described above works satisfactorily when the number of strata is small relative to the amount of data.[src] If we hold the number of strata fixed and increase the amount of data, estimates of the model parameters ( \alpha_i for each stratum and the vector \boldsymbol\beta ) converge to their true values.[src] Pathological behavior, however, occurs when we have many small strata because the number of parameters grow with the amount of data.[src] For example, if each stratum contains two datapoints, then the number of parameters in a model with N datapoints is N/2 + p , so the number of parameters is of the same order as the number of datapoints.[src] In these settings, as we increase the amount of data, the asymptotic results on which maximum likelihood estimation is based on are not valid and the resulting estimates are biased.[src] Conditional logistic regression fixes this issue.[src] In fact, it can be shown that the unconditional analysis of matched pair data results in an estimate of the odds ratio which is the square of the correct, conditional one.[src] In addition to tests based on logistic regression, several other tests existed before conditional logistic regression for matched data as shown in related tests.[src] However, they did not allow for the analysis of continuous predictors with arbitrary stratum size.[src] All of those procedures also lack the flexibility of conditional logistic regression and in particular the possibility to control for covariates.[src] ==Conditional likelihood== Conditional logistic regression uses a conditional likelihood approach that deals with the above pathological behavior by conditioning on the number of cases in each stratum.[src] This eliminates the need to estimate the strata parameters.[src] When the strata are pairs, where the first observation is a case and the second is a control, this can be seen as follows \begin{align} & \mathbb{P}(Y_{i1}=1,Y_{i2}=0|X_{i1},X_{i2},Y_{i1}+Y_{i2}=1) \\ & =\frac{\mathbb{P}(Y_{i1}=1|X_{i1}) \mathbb{P}(Y_{i2}=0|X_{i2})}{\mathbb{P}(Y_{i1}=1|X_{i1}) \mathbb{P}(Y_{i2}=0|X_{i2})+\mathbb{P}(Y_{i1}=0|X_{i1}) \mathbb{P}(Y_{i2}=1|X_{i2})}\\[6pt] \ & =\frac{\frac{\exp(\alpha_i+\boldsymbol{\beta}^\top X_{i1})}{1+\exp(\alpha_i+\boldsymbol{\beta}^\top X_{i1})}\times\frac{1}{1+\exp(\alpha_i+\boldsymbol{\beta}^\top X_{i2})}}{\frac{\exp(\alpha_i+\boldsymbol{\beta}^\top X_{i1})}{1+\exp(\alpha_i+\boldsymbol{\beta}^\top X_{i1})}\times\frac{1}{1+\exp(\alpha_i+\boldsymbol{\beta}^\top X_{i2})}+\frac{1}{1+\exp(\alpha_i+\boldsymbol{\beta}^\top X_{i1})}\times\frac{\exp(\alpha_i+\boldsymbol{\beta}^\top X_{i2})}{1+\exp(\alpha_i+\boldsymbol{\beta}^\top X_{i2})}}\\[6pt] \ & =\frac{\exp(\boldsymbol{\beta}^\top X_{i1})}{\exp(\boldsymbol{\beta}^\top X_{i1})+\exp(\boldsymbol{\beta}^\top X_{i2})}.[src] \\[6pt] \end{align} With similar computations, the conditional likelihood of a stratum of size m , with the k first observations being the cases, is \mathbb{P}(Y_{ij}=1\text{ for }j\leq k,Y_{ij}=0\text{ for } k where \mathcal{C} _{k}^{m} is the set of all subsets of size k of the set \{1,...,m\} .[src] The full conditional log likelihood is then simply the sum of the log likelihoods for each stratum.[src] The estimator is then defined as the \beta that maximizes the conditional log likelihood.[src] ==Implementation== Conditional logistic regression is available in R as the function clogit in the survival package.[src] It is in the survival package because the log likelihood of a conditional logistic model is the same as the log likelihood of a Cox model with a particular data structure.[src] It is also available in python through the statsmodels package starting with version 0.14.[src] ==Related tests== A paired difference test can test the association between a binary outcome and a continuous predictor while taking into account pairing.[src] A Cochran-Mantel-Haenszel test can test the association between a binary outcome and a binary predictor while taking into account stratification with arbitrary strata size.[src] When its conditions of application are verified, it is identical to the conditional logistic regression score test.[src] ==Notes==[src]
49 sentences · 49 cited inline · 0 references stored
References
No reference rows published for this article.
Cite this article
MLA
"Conditional logistic regression." encyclopegia.org, 2025, https://encyclopegia.org/wiki/conditional-logistic-regression. Accessed 02 December 2026.
Chicago
"Conditional logistic regression." encyclopegia.org. Accessed December 2, 2026. https://encyclopegia.org/wiki/conditional-logistic-regression.
APA
encyclopegia.org. (2025). Conditional logistic regression. Retrieved December 2, 2026, from https://encyclopegia.org/wiki/conditional-logistic-regression
Accessed December 2, 2026 · CC BY-SA 4.0 · citation page · JSON