pystacked and ddml: machine learning for prediction and causal inference in Stata
Achim Ahrens,
Christian Hansen,
Mark Schaffer () and
Thomas Wiemann
Additional contact information
Thomas Wiemann: University of Chicago
UK Stata Conference 2023 from Stata Users Group
Abstract:
pystacked implements stacked generalization (Wolpert 1992) for regression and binary classification via Python’s scikit-learn. Stacking is an ensemble method that combines multiple supervised machine learners — the "base" or "level-0" learners — into a single learner. The currently-supported base learners include regularized regression (lasso, ridge, elastic net), random forest, gradient boosted trees, support vector machines, and feed-forward neural nets (multilayer perceptron). pystacked can also be used to fit a single base learner and thus provides an easy-to-use API for scikit-learn’s machine learning algorithms. ddml implements algorithms for causal inference aided by supervised machine learning as proposed in "Double/debiased machine learning for treatment and structural parameters" (Econometrics Journal 2018). Five different models are supported, allowing for binary or continuous treatment variables and endogeneity in the presence of high-dimensional controls and/or instrumental variables. ddml is compatible with many existing supervised machine learning programs in Stata, and in particular has integrated support for pystacked, making it straightforward to use machine learner ensemble methods in causal inference applications.
Date: 2023-09-10
New Economics Papers: this item is included in nep-big, nep-cmp and nep-ger
References: Add references at CitEc
Citations:
Downloads: (external link)
http://repec.org/lsug2023/Stata_UK23_Schaffer1.pdf
http://repec.org/lsug2023/Stata_UK23_Schaffer1.pdf
Related works:
Working Paper: pystacked and ddml: Machine learning for prediction and causal inference in Stata (2023)
This item may be available elsewhere in EconPapers: Search for items with the same title.
Export reference: BibTeX
RIS (EndNote, ProCite, RefMan)
HTML/Text
Persistent link: https://EconPapers.repec.org/RePEc:boc:lsug23:12
Access Statistics for this paper
More papers in UK Stata Conference 2023 from Stata Users Group Contact information at EDIRC.
Bibliographic data for series maintained by Christopher F Baum ().