Md Sohel Mahmood
1 min readApr 13, 2023

--

Hello Donglongyu,

Thanks for reading the article. In this logistic regression, the odd ratios of being at or below a category is obtained by the command reverse=False as you can see in the code. The coefficients will be positive if reverse=True is provided. The negative sign mean there is a negative relationship between marital status and the log odds of being at or below a category. The odd ratio obtained by exponent of the coefficients will be always positive. If odd ratio is less than 1 (in this case it is 0.513), it means the odds of being at or below a particular category decrease by a factor of 0.513 for one unit increase in predictor (which is marital status in this case).

If reverse=True is provided, the coefficients will be positive and odd ratios will be >1. It will mean that the odds of being at or above a particular category increase by a factor of 1.95 for one unit increase in predictor (which is marital status in this case).

--

--

Md Sohel Mahmood
Md Sohel Mahmood

Responses (1)