Statsmodels Anova for logistic regression
Asked Answered
S

0

11

I found the statsmodels implementation of the anova testing for linear models to be very useful (http://www.statsmodels.org/dev/generated/statsmodels.stats.anova.anova_lm.html#statsmodels.stats.anova.anova_lm) but I was wondering, since it's not present in the library, how one could approach building the equivalent version for the logistic regression part.

formulas:

from statsmodels.formula.api import ols, logit
import statsmodels.api as sm

ols(formula_str, data=data_on_which_to_perform_analysis).fit()
logit(formula_str, data=data_on_which_to_perform_analysis).fit()

sm.stats.anova_lm()

which means essentially (by looking at the source code) replicating anova_single. has anyone already done this meaybe in some remote repository? I ask because the imlementation goes very fast and very deep into the statsmodels core library so it's not so easy to work around it (at least with my current level of skill)

any advice on how to proceed?

Silica answered 13/4, 2018 at 14:38 Comment(1)
I believe rmstmppr awsered it hereStarshaped

© 2022 - 2024 — McMap. All rights reserved.