binsreg-package: Binsreg Package Document

binsreg-packageR Documentation

Binsreg Package Document

Description

Binscatter provides a flexible, yet parsimonious way of visualizing and summarizing large data sets and has been a popular methodology in applied microeconomics and other social sciences. The binsreg package provides tools for statistical analysis using the binscatter methods developed in Cattaneo, Crump, Farrell and Feng (2024) and Cattaneo, Crump, Farrell and Feng (2026). binsreg implements binscatter least squares regression with robust inference and plots, including curve estimation, pointwise confidence intervals and uniform confidence band. binsqreg implements binscatter quantile regression with robust inference and plots, including curve estimation, pointwise confidence intervals and uniform confidence band. binsglm implements binscatter generalized linear regression with robust inference and plots, including curve estimation, pointwise confidence intervals and uniform confidence band. binstest implements binscatter-based hypothesis testing procedures for parametric specifications of and shape restrictions on the unknown function of interest. binspwc implements hypothesis testing procedures for pairwise group comparison of binscatter estimators and plots confidence bands for the difference in binscatter parameters between each pair of groups. binsregselect implements data-driven number of bins selectors for binscatter implementation using either quantile-spaced or evenly-spaced binning/partitioning. All the commands allow for covariate adjustment, smoothness restrictions, and clustering, among other features.

The companion software article, Cattaneo, Crump, Farrell and Feng (2025), provides further implementation details and empirical illustration. For related Stata, R and Python packages useful for nonparametric data analysis and statistical inference, visit https://nppackages.github.io/.

Author(s)

Matias D. Cattaneo (maintainer). matias.d.cattaneo@gmail.com.

Richard K. Crump. richard.crump@gmail.com.

Max H. Farrell. mhfarrell@gmail.com.

Yingjie Feng. fengyingjiepku@gmail.com.

References

Cattaneo, M. D., R. K. Crump, M. H. Farrell, and Y. Feng. 2024: On Binscatter. American Economic Review 114(5): 1488-1514.

Supplemental Appendix for On Binscatter: Supplemental Appendix.

Cattaneo, M. D., R. K. Crump, M. H. Farrell, and Y. Feng. 2026: Nonlinear Binscatter Methods. Review of Economics and Statistics, revise and resubmit.

Supplemental Appendix for Nonlinear Binscatter Methods: Supplemental Appendix.

Cattaneo, M. D., R. K. Crump, M. H. Farrell, and Y. Feng. 2025: Binscatter Regressions. Stata Journal 25(1): 3-50.

See Also

Useful links:


binsreg documentation built on May 15, 2026, 5:06 p.m.