Model
Every estimator in Litux is validated against R to six decimal places on coefficients and four on standard errors. This page documents each one: when to use it, its assumptions, how to configure it, and what replication code it generates.
OLS
What it is. Ordinary least squares — the workhorse linear model. Use it when you want the conditional mean of a continuous outcome and you are willing to assume exogeneity of the regressors.
Assumptions. Linearity, exogeneity (E[ε|X] = 0), no perfect collinearity. Homoskedasticity is not required — pick a robust standard-error type instead.
Step by step.
- In Model, choose OLS from the estimator menu.
- Pick your outcome (Y) and regressors (X). Categorical variables expand to dummies automatically (first level dropped).
- Open Inference to choose standard errors: classical, HC0–HC3, clustered (one- or two-way), or Newey-West HAC.
- Hit Estimate. The coefficient table reports estimates, SEs, t-statistics and p-values; diagnostics (Breusch-Pagan, Jarque-Bera, VIF) are one tab away.
Validation. Coefficients match R’s lm() to 6 decimals; robust SEs match sandwich::vcovHC / vcovCL to 4.
Replication. The exported R script uses fixest::feols with your exact SE choice; Stata uses reg ..., vce(); Python uses pyfixest.
Instrumental variables (2SLS, GMM, LIML)
When regressors are endogenous. Covers instrument choice, first-stage diagnostics, weak-instrument F, Hansen J.
Panel (FE, FD, TWFE, LSDV)
Within-transformations, first differences, two-way fixed effects, panel-robust inference.
Difference-in-differences & event studies
2x2 DiD, TWFE DiD, event studies, staggered adoption (Callaway-Sant’Anna, Sun-Abraham).
Regression discontinuity
Sharp and fuzzy designs, IK bandwidth, McCrary density test, polynomial orders.
Limited dependent outcomes
Logit, probit, Poisson FE, negative binomial — marginal effects included.
Synthetic control
Frank-Wolfe weight solver with placebo inference.
Hypothesis tests
Post-estimation single and joint (Wald) tests on coefficients.