10
$\begingroup$

I'm trying to understand the use of logistic regression in 2x2 and Ix2 contingency tables. For instance, using this as an example

enter image description here

What is the difference between using chi-square test and using logistic regression? What about a table with multiple nominal factors (Ix2 table) like this:

enter image description here

There is a similar question here - but the answer is mainly that chi-square can handle mxn tables, but my question is what is specificalyl for when there is a binary outcome and a single nominal factor. (The linked thread also refers to this thread, but this is regarding mutiple variables/factors).

If it's just a single factor (i.e. no need to control for other variables) with a binary response, what is the purpose difference of doing logistic regression?

$\endgroup$
11
$\begingroup$

Ultimately, it's apples and oranges.

Logistic regression is a way to model a nominal variable as a probabilistic outcome of one or more other variables. Fitting a logistic-regression model might be followed up with testing whether the model coefficients are significantly different from 0, computing confidence intervals for the coefficients, or examining how well the model can predict new observations.

The χ² test of independence is a specific significance test that tests the null hypothesis that two nominal variables are independent.

Whether you should use logistic regression or a χ² test depends on the question you want to answer. For example, a χ² test could check whether it is unreasonable to believe that a person's registered political party is independent of their race, whereas logistic regression could compute the probability that a person with a given race, age, and gender belongs to each political party.

$\endgroup$
  • $\begingroup$ Thanks. Would you be able to give me an example of the different type of questions you can answer with the different methods? Are there any specific resources you can recommend for understanding the different questions that can be answered with the two methods? $\endgroup$ – L Xandor Oct 21 '15 at 20:52
  • $\begingroup$ I added examples to my answer. Regarding your second question, Wikipedia is a decent place to begin. Also, most introductory applied statistics textbooks will mention both the χ² test of independence and logistic regression. $\endgroup$ – Kodiologist Oct 21 '15 at 22:03
  • $\begingroup$ Thanks. I'm still unclear of what the difference is in the specific case of a 2x2 contignency table? chi square would check if the outcome is independent of the variations of the factor, but what does logistic regression do here? I understand LR is useful for doing predictions based on a series of factors, but when it comes to the simple 2x2 I'm not sure what the difference is (but it's clearly used)...could you (or anyone) use the 2x2 stress/reflux table in the original post as a concrete example of how they would be used differently? It's the single factor case that I'm most interested in $\endgroup$ – L Xandor Oct 22 '15 at 1:46
  • $\begingroup$ or the race/political party works just as well as an example, but when you then use logistic regression you are using multiple factors, and I can see how it is useful there...but what I specifically have a hard time understanding is why use LR (or how is it different) in the single factor case. If both methods are used to examine relationship between race and political party, what's the difference between chi square and logistic regression? $\endgroup$ – L Xandor Oct 22 '15 at 1:50
  • $\begingroup$ In the case of the stress and reflux example, you could use logistic regression to test whether stress significantly affects the probability of reflux, or you could compute a confidence interval for the odds ratio expressing this effect. One way in which this is conceptually different from a χ² test is that one of stress or reflux is construed as the dependent variable. But in any case, logistic regression may be considered overkill for a 2-by-2 contingency table. $\endgroup$ – Kodiologist Oct 22 '15 at 12:10

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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