Data Science, Causal Inference, Linear Regression, Getting Started, Ab Testing.
model is straightforward — we just need to add another component to the equation. import statsmodels.formula.api as smf model = smf.ols('time_spent_mins ~ treatment + complexity', data=df).fit() model.summary().tables[1] Now, we see a bit higher estimation of the effect — 1.91 vs 1.87 minutes.