Logistic regression Flashcards
OLS assumptions violated
1) Non-normal error term (b/c bimodal distribution)
2) Non-constant error variance
3) Problem with range of outcome (OLS assumes -infinity to +infinity)
Odds of observing outcome
Odds(1) = π / (1-π)
Odds bound (0 to infinity)
By taking natural logarithm of odds, transform response probability to be bound on (-infinity to +infinity)
Logit link function
Logit(π / (1-π)) = log(e) (π / (1-π))
Equation with 1 predictor
logit(π / (1-π)) = β0 + β1X1 + ε
Interpreting model
If X is continuous, and β >0, say: Log odds of event occurring increase as X increases.
If X is continuous, and β
Odds ratio
exp(β), or e&β
Interpret: As X increases by 1 unit, the odds of seeing the outcome increase (or decrease) by exp(β)
If exp(β) is 1, odds of observing outcome &y-1) is the same for individuals regardless of level of x.
If exp(β) 1, odds of observing outcome is exp(β)-1 higher for individuals with x=1 compared to individuals with x=0.
Significance of predictors
Test in same fashion as the OLS model. β / se(β) as t-statistic or z-statistic.
Or calculate Wald chi square statistic: β^2 / (se(β))^2.
Other link functions
Probit: Inverse of the cumulative normal distribution function.
Log-log link:
How to choose link function? If p(π) relatively large, doesn’t matter. If very rare events (p 95%), choice makes a difference.