OLS with robust standard errors
Few controls that enter linearly
With fewer than 10 controls and no sign of nonlinearity, OLS already adjusts for the confounders; report the DML estimate as a robustness check …
Lecture 02: OLS inference →The right method depends on your question and on your data, not on fashion. Decide first whether you want to predict an outcome or estimate a causal effect; then the tests below choose between LASSO, ridge, elastic net, random forest and XGBoost, or between OLS and double machine learning.
Nine real datasets: five prediction problems and four causal questions. Each one leads to a different method.
First choose the aim. Then upload a CSV with one row per observation: the outcome in the first column, then the other variables.
Drop a CSV file here, or
Your file is analysed on your own device and is not uploaded anywhere. Numeric columns only (code categories as 0/1 dummies). A column named year, quarter, month or date marks the data as a time series; for forecasting, enter the predictors already lagged (for example infl_l1). Files above 4,000 rows are subsampled for the forest checks. Format examples: econmath.csv (prediction), k401_irm.csv (causal).
Use this if you have already run the checks. If you have not, choose “Use my own data” and they are run and explained for you.
Each guide takes one real dataset through tuning, validation, diagnostics and writing, with Python code, real output and sample text for the paper.
Few controls that enter linearly
With fewer than 10 controls and no sign of nonlinearity, OLS already adjusts for the confounders; report the DML estimate as a robustness check …
Lecture 02: OLS inference →Selection on unobservables, no instrument
Machine learning cannot fix confounding by variables you do not observe. Use a research design: difference-in-differences, synthetic control or regression discontinuity …
Open the Causal Inference Guide →