A guided reading path
Regression and inference: fit, read and question a model
A regression table is the beginning of an argument. Learn what its estimates mean, where the uncertainty comes from and which conclusions the design can support.
01 · Understand the question
Build the foundations
Read in this order, or open the question you are working on.
What is regression analysis? A worked example in Python
Regression analysis describes how the average of one variable changes with others. Learn to fit, read and question a linear regression, step by step.
How to read regression results: coefficients, uncertainty and fit
Read a regression table in context: check the sample and units, interpret coefficients and confidence intervals, compare models and separate fit from causality.
P-values in economics: what they mean and what they do not
A p-value measures how surprising the data would be under a null hypothesis. Learn to read it correctly, avoid common mistakes and report uncertainty well.
Robust and clustered standard errors in Python, from HC0 to the wild bootstrap
How HC0–HC3, cluster-robust and HAC standard errors work, when each is appropriate, and why a handful of clusters calls for the wild cluster bootstrap.
02 · Examine the assumptions
Explore methods when you need them
A clear description may already answer your question. If modelling is useful, these references explain the estimator, supported options, a runnable example and limitations. Choose one for your question and assumptions.
-
Linear models and IV
OLS regression in Python with robust and clustered standard errors
Fit OLS and weighted least squares in Python with HC0–HC3, clustered or HAC standard errors, then run tests, linear combinations and margins.
-
Linear models and IV
Quantile regression in Python: qreg, bootstrap and simultaneous quantiles
Estimate median and other conditional quantiles in Python with qreg, bsqreg and sqreg, and test whether a slope differs across the distribution.
-
Tests and inference
Wild cluster bootstrap in Python: a boottest workflow for few clusters
Run restricted wild cluster bootstrap tests and confidence sets in Python when there are few clusters, the workflow of the boottest command in Stata.
03 · Work through the evidence
Try a worked lab
These exercises use synthetic teaching data. The full handout, Python analysis and available resources are linked on each lab page.
Worked lab
Fit and interpret a regression
Use a class-size question to connect a coefficient with its units and assumptions.
Worked lab
Understand what controls change
Compare specifications and investigate why a coefficient moves.
Worked lab
Check the uncertainty estimate
Compare conventional and robust inference without changing the research question.
Try it on your own data
OpenEconometrics is free and open source under Apache 2.0. Install the Python library or download the desktop alpha.
pip install openecon