4
$\begingroup$

I would like to expand on this question. Knowing that it is possible to do a logistic regression when the IV is dichotomous, and that I've seen it done in studies: what is the purpose of doing so, and what would be the advantages over using the usual Pearson X-square or (if a non-categorical version of the predictor is available) a simple t-test?

$\endgroup$
3
  • $\begingroup$ How could you use the t test when both variables are dichotomous? $\endgroup$
    – user158565
    Dec 11, 2018 at 15:15
  • 1
    $\begingroup$ For instance if the predictor was made dichotomous by binning, one could go back to an ordinal variable (e.g. grade instead of pass/fail) and perform a t-test. $\endgroup$
    – GuillaumeL
    Dec 11, 2018 at 16:39
  • 1
    $\begingroup$ "what is the purpose of doing so?" Showoff. "what would be the advantages over using the usual Pearson X-square?" No. $\endgroup$
    – user158565
    Dec 12, 2018 at 3:19

1 Answer 1

6
$\begingroup$

In terms of fit to the data, any GLM will give equivalent fit in a binary-binary situation. So if you do the regression and check the predicted probabilities, they'll all be the same regardless of which GLM or link function you use. See page 175 of Wacholder (1986) below.

Pearson $\chi^2$ test (without continuity correction) will be equivalent to Rao's score test of the logistic regression model, so they are practically equivalent. And the G test is equivalent to the likelihood ratio rest from the logistic regression. The default test in most packages is a Wald test.

A linear regression or t-test may be faulty because binary data implies heteroskedasticity on the scale of the binary response. So Welch's t-test might actually be acceptable for inference.

The t-test will give the simplest interpretation. The mean difference is the difference in probabilities between the two groups.

UPDATE

As @AdamO pointed out in the comments, you can also do a GLM with binomial distribution and identity link function. Sometimes, this model will not converge in software but it definitely will when the lone predictor is dichotomous. This has the advantage of estimating the correct mean difference with an adequate variance structure. If you perform the score test, the inference will again be no different from logistic regression.


SHOLOM WACHOLDER; BINOMIAL REGRESSION IN GLIM: ESTIMATING RISK RATIOS AND RISK DIFFERENCES, American Journal of Epidemiology, Volume 123, Issue 1, 1 January 1986, Pages 174–184, https://doi.org/10.1093/oxfordjournals.aje.a114212

$\endgroup$
2
  • 3
    $\begingroup$ +1 very nice answer. I thought the Pearson Chi-sq test was the score test for the logistic likelihood, though. If the OP wants a test of the proportion difference, another approach worth considering is using a GLM with binomial variance structure and identity link. This is an "additive risk" model (or whatever the nature of the outcome is). $\endgroup$
    – AdamO
    Dec 12, 2018 at 16:35
  • $\begingroup$ @AdamO I agree, binomial distribution with identity (and log) link is the actual recommendation in Wacholder's paper. Pearson Chi-sq test for two-by-two contingency tables is the score test for the binomial likelihood. $\endgroup$ Dec 14, 2018 at 18:34

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.