Software

Software packages for applied econometrics and data analysis.

R Packages

lwdidR

R implementation of the Lee & Wooldridge (2025) panel difference-in-differences estimator via unit-specific pre-treatment transformations.

endid

Engression-based distributional difference-in-differences. Combines Lee & Wooldridge (2025) panel DiD transformations with engression distributional regression to estimate quantile treatment effects (QTE) and counterfactual distributions. Supports both common-timing and staggered adoption designs with parallel bootstrap inference.

Rnetrics

R port of Bryan Graham’s ipt and netrics Python packages. Implements dyadic regression with bias-corrected dyadic-robust standard errors following Graham (forthcoming, Handbook of Econometrics).

Rfrengression

Native R package for frengression — causal data simulation via deep generative models. Learns joint distributions of treatments, outcomes, and confounders from observational data, enabling interventional sampling and custom causal margin specification. Implements cross-sectional, longitudinal, and survival model classes. Based on Shen & Meinshausen (2025, arXiv:2508.01018).

RCausalModel

R package for causal inference in observational studies, randomized experiments, and network interference settings. Implements OLS, IPW, AIPW, matching, DML, difference-in-means, stratified, ANCOVA, Fisher exact test, and clustered IPW/AIPW estimators. Based on Qu, Xiong, Liu & Imbens (2021).

dma

Distributional Mediation Analysis using energy regression. Implements the semiparametric mediation framework of Liu, Williams, Rudolph & Díaz (2024) with engression replacing traditional ML ensembles for outcome regressions and Riesz representer estimation. Supports natural, organic, randomized interventional, and recanting twins effect decompositions with full observation weight propagation, counterfactual density visualization via Riesz representer importance weighting, and richer result objects storing trained models for post-hoc diagnostics.

divR

Distributional Instrumental Variable regression in R. Implements the DIV method of Holovchak, Saengkyongam, Meinshausen & Shen (2025, arXiv:2502.07641), using energy score-based generative modelling to estimate the full interventional distribution P(Y|do(X)) in the presence of unmeasured confounding. Yields interventional means, quantiles, and samples. Includes vignettes reproducing all simulation studies and real-data applications from the paper.

dyadfast

Fast dyadic-robust variance estimation for R. Implements the Aronow, Samii & Assenova (2015) cluster-robust variance estimator for dyadic data via a single O(nK) scatter-add pass.

didint

Doubly robust difference-in-differences with spatial interference. Implements the 2x2 estimator of Xu (2023, arXiv:2306.12003) and the dynamic / staggered-adoption extensions of Xu (2026, AEA P&P 116: 58-63). Three propensity models plus two outcome regressions, joint-IF aggregation across cohort-time cells, optional propensity-score trim and Conley spatial-HAC SEs. Vignette replicates the Brazil Amazon Lista de Municípios Prioritários application. Docs site.

tvhte

Time-varying heterogeneous treatment effects in event studies. Implements Botosaru & Liu (2025, arXiv:2509.13698) — a dynamic panel with correlated random coefficients on \((\alpha_i, \delta_{i0})\) and AR(1) event-time effects, two-step QMLE + Tweedie/Gaussian empirical Bayes for unit-level posterior trajectories. Also Botosaru & Liu (2026, AEA P&P 116: 70-74) — homogeneous covariate-feedback factorisation with direct/indirect counterfactual decomposition. Handles staggered cohorts (including never-treated). Docs site.

Python Packages

torch-engression

GPU-accelerated distributional regression via energy scores. A PyTorch-native reimplementation of engression (Shen & Meinshausen, 2024) with automatic GPU acceleration, mixed precision training, and torch.compile support.

torch-endid

GPU-accelerated distributional difference-in-differences via engression. Combines lwdid panel transformations (Lee & Wooldridge, 2025) with torch-engression GPU-accelerated distributional regression to produce ATT, quantile treatment effects (QTE), and counterfactual distributions from panel data.

netrics-fast

Memory-efficient dyadic regression with bias-corrected dyadic-robust standard errors, following Graham (forthcoming, Handbook of Econometrics). Fast reimplementation of netrics.dyadic_regression using chunked O(nK) scatter-add Hajek projection.

Julia Packages

TASC.jl

Julia implementation of Time-Aware Synthetic Control (Rho, Illick, Narasipura, Abadie, Hsu & Misra, 2026, arXiv:2601.03099). Fits low-rank state-space models with Kalman filtering, RTS smoothing, EM learning, model-based confidence bands, multiple treated units, classical synthetic-control baselines, simulation utilities, and plotting recipes.

MSC.jl

Julia implementation of multivariate synthetic control for high-dimensional disaggregated panels, inspired by Shen, Song & Abadie (2025). Estimates sparse treated-unit counterfactuals for many treated units at once using a multivariate square-root Lasso objective, with matrix and DataFrame APIs, cross-validation, diagnostics, placebo routines, plotting recipes, and a runnable county-unemployment application that matches the paper’s reported sample counts.

SynthDiD.jl

Julia implementation of Synthetic Difference-in-Differences (Arkhangelsky, Athey, Hirshberg, Imbens & Wager, 2021, AER). Provides all three estimators (SDiD, SC, DiD), bootstrap/jackknife/placebo standard errors, per-period effect curves, and Plots.jl recipes — translated from the R synthdid package.

Engression.jl

Julia implementation of Engression — distributional regression via energy scores (Shen & Meinshausen, 2024). Estimates the entire conditional distribution P(Y|X) by training a stochastic neural network, particularly useful for non-Gaussian, multi-modal, or heteroskedastic conditional distributions.

Endid.jl

Julia implementation of distributional difference-in-differences using Engression. Follows Lee & Wooldridge (2025), leveraging stochastic neural networks to estimate entire treatment effect distributions including quantile treatment effects (QTE). Supports both common-timing and staggered adoption designs.

CausalEstimate.jl

Unified Julia front-end for causal effect estimation. Provides a single estimate(...) interface for typed estimands such as ATE and ATT, with TMLE and AIPW backends, cross-fitting, doubly robust inference, and graph-implied backdoor adjustment through CausalGraphs.jl.

Panelest.jl

High-performance panel data estimation with high-dimensional fixed effects. Implements OLS, Poisson, Logit, Probit, Chamberlain’s conditional logit, and Wooldridge’s correlated random effects (CRE) via IRLS with FixedEffects.jl absorption, mirroring R’s fixest API. v0.1.3 adds etwfe() — a one-call Wooldridge ETWFE estimator that defaults to cohort FE + year FE (the correct specification, avoiding the contamination bias from unit FE), supports family="poisson" for count outcomes, and returns an ETWFEResult with a dedicated emfx() method for ATT, event-study, and calendar-time aggregation.

Lavaan.jl

Julia port of the R lavaan package for Structural Equation Modeling, using the same model syntax for easy migration. Supports CFA, SEM, latent growth curves, generalized SEM with Poisson/mixed indicators, Structural After Measurement (SAM), ordinal DWLS/WLSMV estimation, multilevel and crossed-effects models, labeled paths, and defined parameters — with 326 tests and 7 Quarto vignettes.

Crumble.jl

Julia implementation of causal mediation analysis via cross-fitted nuisance estimation and linear optimal transport permutation for instrument construction. Estimates natural direct and indirect effects with support for continuous treatments, multiple mediators, instrumental variables (with one-hot encoding for categorical instruments), and clustered cross-fitting.

RDRobust.jl

Julia port of the rdrobust package for Regression Discontinuity designs (Calonico, Cattaneo, Farrell & Titiunik). Provides local polynomial point estimators with robust bias-corrected confidence intervals (rdrobust), data-driven MSE/CER-optimal bandwidth selection (rdbwselect), and RD plot construction (rdplot), with support for fuzzy RD, covariate adjustment, and cluster-robust inference.

CausalGraphs.jl

Unified Julia package for graph-based causal inference in acyclic directed mixed graphs (ADMGs) and missingness DAGs (mDAGs). Provides graph construction and visualization, identification routines, backdoor/front-door/nested-fixable estimation, TMLE/one-step/IPW/G-computation estimators, missing-data identification and weighting, and a single estimate_causal() entry point that auto-routes by identification strategy.

DidInterference.jl

Julia port of didint. Doubly robust difference-in-differences with spatial interference (Xu 2023, 2026). Same estimators, same trim and joint-IF aggregation behaviour as the R companion. Docs site.

TVHTE.jl

Julia port of tvhte. Time-varying heterogeneous treatment effects in event studies (Botosaru & Liu 2025, 2026): dynamic panel with correlated random coefficients on \((\alpha_i, \delta_{i0})\), AR(1) event-time effects, QMLE + Gaussian-conjugate empirical Bayes, plus homogeneous covariate-feedback factorisation with direct/indirect counterfactual decomposition. Docs site.

ShiftShareIV.jl

Julia toolkit for shift-share (Bartik) instrumental variables. Implements bartik_iv for constructing the instrument \(B_\ell = \sum_k s_{\ell k} g_k\), rotemberg_weights for the GPSS (2020) decomposition that expresses the 2SLS estimate as a weighted average of industry-specific IV estimates, and bhj_collapse for the BHJ (2022) shock-level data aggregation used for inference robust to cross-location correlation from shared shocks.