In this article, I am going to show you why the odds ratio for an -variable in a logistic regression is simply the exponential of the regression coefficient. This article just contains “the math” and no interpretation. A discussion of interpretation of the odds ratio in logistic regression can be found here. A more basic discussion, that includes definitions of “odds” and “odds ratio” can be found here.
Before I begin, I want to remind you of a basic property of exponents from algebra. Specifically, when two like terms are multiplied together, the exponents add. For example,
In what follows, I will actually be going the other way: .
As I expect you know, in logistic regression, the log odds is a linear function of the ‘s:
The odds, then, can be found by exponentiating both sides:
What we want to know is what happens to the odds when we add 1 unit to one of the ‘s. We will assess the effect of this change using the odds ratio.
So let’s suppose that we considering a 1-unit change in . In that case, the new odds are given by
Note that I have used a subscript of “new” on the to show that this is the “new” , and thus the new odds that corresponds to adding 1-unit to .
I am now going to rearrange the right hand side of this equation, first by multiplying out and then by pulling out the term using the exponent formula given above. Thus,
We can now use this formula to compute the odds ratio:
Now notice that the in both the top and the bottom divide out, so we are left with
Thus, the odds ratio corresponding to a 1-unit change in an -variable is just the exponential of the ‘s regression coefficient.
Questions or Comments?
Any questions or comments? Please feel free to comment below. I am always wanting to improve this material.
I have had to implement a very simple “captcha” field because of spam comments, so be a bit careful about that. Enter your answer as a number (not a word). Also, save your comment before you submit it in case you make a mistake. You can use cntrl-A and then cntrl-C to save a copy on the clipboard. Particularly if your comment is long, I would hate for you to lose it.