EconStatsCraft rigorous, plain-spoken econometrics
Econometrics that explains itself.
Regression, panel data, time series and the whole battery of tests. Every result is followed by a verdict you can defend.
Load a dataset to see it here.
EconStatsCraft › Truncated regression
For a sample that only contains observations on one side of a cut - survey of earners above a threshold, firms above a size. Unlike censoring the missing rows are simply not there, so the errors in what survives no longer average zero and OLS is biased.
Truncation is worse than censoring. Under censoring you at least know how many observations hit the limit; under truncation they are not in your data at all. A survey of people earning above a threshold does not record the people below it, and does not tell you how many there were. Fitting OLS to what survives estimates the relationship among the survivors, which is systematically flatter than the relationship in the population.
The sampling frame itself excludes part of the population: a survey of people earning above a threshold, firms above a size, students who scored high enough to enrol.
Observations are drawn only where y_i>a. The density must be renormalised to integrate to one over the observed region: f(y\mid y>a)=\frac{\phi\!\left(\frac{y-x'\beta}{\sigma}\right)/\sigma}{1-\Phi\!\left(\frac{a-x'\beta}{\sigma}\right)}, and the log-likelihood is the sum of its logs. The bias in OLS follows from the truncated mean, E[y\mid y>a,x]=x'\beta+\sigma\lambda(\alpha) with \alpha=(a-x'\beta)/\sigma and \lambda(\alpha)=\phi(\alpha)/(1-\Phi(\alpha)) the inverse Mills ratio. Because \lambda depends on x, the omitted term is CORRELATED with the regressors, which is precisely the structure of omitted-variable bias.
E[y\mid \mathbf{x},y>c]=\mathbf{x}^{\prime}\boldsymbol{\beta}+\sigma\,\frac{\phi(\alpha)}{1-\Phi(\alpha)},\qquad \alpha=\frac{c-\mathbf{x}^{\prime}\boldsymbol{\beta}}{\sigma}
A wage equation estimated only on people earning above a reporting threshold. The population slope on schooling is 0.09; OLS on the truncated sample returns roughly 0.06, and truncated regression recovers 0.088. The gap is not sampling noise - it survives any sample size - because the inverse Mills ratio omitted from OLS is a function of the regressors and behaves exactly like an omitted variable correlated with schooling. Note also what cannot be checked: nothing in the surviving data reveals whether the errors below the threshold were normal, and the whole estimate rests on assuming they were.
| If you see this | It means | Do this |
|---|---|---|
| Estimates much larger than OLS | Expected. OLS was flattened by the truncation | Not evidence of an error |
| Sigma implausibly large | The model extrapolating far below the truncation point | Weak identification; be sceptical |
| Truncation share above about half | Very little information survives | Results will be fragile and heavily distribution-dependent |
| Non-normal residuals | The estimator is inconsistent | No robust standard error fixes this. Consider a semiparametric estimator |
| You actually know how many were dropped | This is censoring, not truncation | Use Tobit, which is more efficient |
| Truncation is on a regressor | No bias in the slope | Do not apply this model |
Tobit, for when the limit observations are recorded rather than dropped. Heckman selection, for truncation driven by a separate equation.
Multiple regression (OLS) · Logit / Probit · Tobit (censored) · Multinomial logit · Ordered logit / probit · Quantile regression · Poisson / Negative binomial
Line chart · Area chart · Bar chart · Stacked bar · Scatter plot · Bubble chart · Histogram · Box plot · Pie chart · Heat map · Rebased to 100 · Lorenz curve and Gini
World map · Bivariate map · Flow map · India - state map · India - district map
Descriptive statistics · Summary by group · Two-way table · Classical statistical tests
Multiple regression (OLS) · Logit / Probit · Tobit (censored) · Truncated regression · Multinomial logit · Ordered logit / probit · Quantile regression · Poisson / Negative binomial
Time-varying coefficients (Kalman) · Unit root tests · Correlogram (ACF / PACF) · ARIMA / SARIMA · Rolling-origin cross-validation · Theta method · Unobserved components · STL forecasting · Forecast combination · Markov regime switching · Change frequency (resample) · ARCH / GARCH volatility · Decompose & filter · Spectral analysis · Exponential smoothing · Forecast accuracy
Yield curve (Nelson–Siegel / Svensson) · Dynamic factor model · Dynamic regression (ARIMAX) · Structural VAR · VAR · Granger causality · Cointegration · VECM · ARDL & bounds test
Panel regression · Panel cointegration tests · Heterogeneous panel: Mean Group & PMG · Gravity model of trade · Dynamic panel GMM · Panel diagnostics · Panel unit-root tests
Principal components (PCA) · Factor analysis · Cluster analysis
Conjoint analysis · MaxDiff (best–worst scaling) · TURF - reach of a product line · Price sensitivity (Van Westendorp) · Market basket analysis · Perceptual map · Scale reliability (Cronbach’s alpha) · Key driver analysis
Spatial autocorrelation · Spatial regression · Heckman selection · Instrumental variables (2SLS) · Difference-in-differences · Staggered difference-in-differences · Regression discontinuity · Matching & weighting · Oaxaca–Blinder decomposition
Black–Scholes option pricing · Bond price, duration & convexity · Merton distance to default · EMI / home loan planner · CAPM / beta estimation · Multi-factor model · Portfolio optimization · Value at Risk & Expected Shortfall · Performance & drawdown · Time value of money & NPV/IRR · Equity valuation (DDM, FCF, residual income) · Cost of capital (WACC) · Binomial option pricing · Option strategies (payoff & profit) · Forwards, futures & swaps · Credit risk & Basel capital · Extreme value theory (tail risk)
Life table · Life annuity · Life insurance pricing · Chain ladder reserving · Buhlmann credibility · Survival analysis · Mortality graduation · Aggregate loss model · Ruin probability · Multi-state Markov model · Loss severity fitting
Monte Carlo experiment · F-test, Wald & Chow · Structural breaks & stability
Regression vs machine learning · Ridge / Lasso / Elastic Net · Random forest · Gradient boosting
EconStatsCraft rigorous, plain-spoken econometrics
Regression, panel data, time series and the whole battery of tests. Every result is followed by a verdict you can defend.
Load a dataset to see it here.
Pick the example closest to your question. You get a spreadsheet with the right columns and a few rows showing the expected format - replace the numbers with your own, then paste or upload it back.
Copy the header row from the table above (or from the downloaded template), put your own rows underneath, and paste the whole thing here. It is checked against the layout before anything is imported.
Or click a row in the preview below.
For a units or notes row.
Search every source at once. World Bank indicators need countries and years; everything else loads in one click.
Loading the catalogue…
The engine stays loaded, so this is quick - and it leaves your open tab and panel layout alone.
⌘/Ctrl+Enter runs the current analysis. ⌘/Ctrl+P exports the session as a PDF. Esc closes this.
In the Notebook: Enter starts a new block and
Shift+Enter a new line inside one; Backspace at the start
joins back into the paragraph above; / on an empty line inserts anything.
⌘/Ctrl+B, I, E, H and
M apply bold, italic, code, highlight and maths.
#, ##, -, 1., > and
``` at the start of a line convert it.
Sign in to run unlimited analyses.
Scroll to pan · Esc to close