IDEAS home Printed from
   My bibliography  Save this paper

Inference in differences-in-differences with few treated groups and heteroskedasticity


  • Ferman, Bruno
  • Pinto, Cristine Campos de Xavier


Differences-in-Differences (DID) is one of the most widely used identification strategies in applied economics. However, how to draw inferences in DID models when there are few treated groups remains an open question. We show that the usual inference methods used in DID models might not perform well when there are few treated groups and errors are heteroskedastic. In particular, we show that when there is variation in the number of observations per group, inference methods designed to work when there are few treated groups tend to (under-) over-reject the null hypothesis when the treated groups are (large) small relative to the control groups. This happens because larger groups tend to have lower variance, generating heteroskedasticity in the group x time aggregate DID model. We provide evidence from Monte Carlo simulations and from placebo DID regressions with the American Community Survey (ACS) and the Current Population Survey (CPS) datasets to show that this problem is relevant even in datasets with large numbers of observations per group. We then derive an alternative inference method that provides accurate hypothesis testing in situations where there are few treated groups (or even just one) and many control groups in the presence of heteroskedasticity. Our method assumes that we can model the heteroskedasticity of a linear combination of the errors. We show that this assumption can be satisfied without imposing strong assumptions on the errors in common DID applications. With many pre-treatment periods, we show that this assumption can be relaxed. Instead, we provide an alternative inference method that relies on strict stationarity and ergodicity of the time series. Finally, we consider two recent alternatives to DID when there are many pre-treatment periods. We extend our inference methods to linear factor models when there are few treated groups. We also derive conditions under which a permutation test for the synthetic control estimator proposed by Abadie et al. (2010) is robust to heteroskedasticity and propose a modification on the test statistic that provided a better heteroskedasticity correction in our simulations.

Suggested Citation

  • Ferman, Bruno & Pinto, Cristine Campos de Xavier, 2015. "Inference in differences-in-differences with few treated groups and heteroskedasticity," Textos para discussão 406, FGV EESP - Escola de Economia de São Paulo, Fundação Getulio Vargas (Brazil).
  • Handle: RePEc:fgv:eesptd:406

    Download full text from publisher

    File URL:
    Download Restriction: no

    Other versions of this item:

    References listed on IDEAS

    1. James G. MacKinnon & Matthew D. Webb, 2016. "Randomization Inference for Difference-in-Differences with Few Treated Clusters," Carleton Economic Papers 16-11, Carleton University, Department of Economics.
    2. Choi, Moonkyung Kate, 2011. "The impact of Medicaid insurance coverage on dental service use," Journal of Health Economics, Elsevier, vol. 30(5), pages 1020-1031.
    3. Stephen G. Donald & Kevin Lang, 2007. "Inference with Difference-in-Differences and Other Panel Data," The Review of Economics and Statistics, MIT Press, vol. 89(2), pages 221-233, May.
    4. Guido W. Imbens & Michal Kolesár, 2016. "Robust Standard Errors in Small Samples: Some Practical Advice," The Review of Economics and Statistics, MIT Press, vol. 98(4), pages 701-712, October.
    5. Joshua D. Angrist & Jörn-Steffen Pischke, 2009. "Mostly Harmless Econometrics: An Empiricist's Companion," Economics Books, Princeton University Press, edition 1, number 8769.
    6. A. Colin Cameron & Jonah B. Gelbach & Douglas L. Miller, 2008. "Bootstrap-Based Improvements for Inference with Clustered Errors," The Review of Economics and Statistics, MIT Press, vol. 90(3), pages 414-427, August.
    7. Marianne Bertrand & Esther Duflo & Sendhil Mullainathan, 2004. "How Much Should We Trust Differences-In-Differences Estimates?," The Quarterly Journal of Economics, Oxford University Press, vol. 119(1), pages 249-275.
    8. Timothy G. Conley & Christopher R. Taber, 2011. "Inference with "Difference in Differences" with a Small Number of Policy Changes," The Review of Economics and Statistics, MIT Press, vol. 93(1), pages 113-125, February.
    9. Kelly Bedard & Chau Do, 2005. "Are Middle Schools More Effective?: The Impact of School Structure on Student Outcomes," Journal of Human Resources, University of Wisconsin Press, vol. 40(3).
    10. White, Halbert, 1980. "A Heteroskedasticity-Consistent Covariance Matrix Estimator and a Direct Test for Heteroskedasticity," Econometrica, Econometric Society, vol. 48(4), pages 817-838, May.
    11. James G. MacKinnon & Matthew D. Webb, 2017. "Wild Bootstrap Inference for Wildly Different Cluster Sizes," Journal of Applied Econometrics, John Wiley & Sons, Ltd., vol. 32(2), pages 233-254, March.
    12. Abadie, Alberto & Diamond, Alexis & Hainmueller, Jens, 2010. "Synthetic Control Methods for Comparative Case Studies: Estimating the Effect of California’s Tobacco Control Program," Journal of the American Statistical Association, American Statistical Association, vol. 105(490), pages 493-505.
    13. A. Colin Cameron & Douglas L. Miller, 2015. "A Practitioner’s Guide to Cluster-Robust Inference," Journal of Human Resources, University of Wisconsin Press, vol. 50(2), pages 317-372.
    14. Brewer Mike & Crossley Thomas F. & Joyce Robert, 2018. "Inference with Difference-in-Differences Revisited," Journal of Econometric Methods, De Gruyter, vol. 7(1), pages 1-16, January.
    15. Alberto Abadie & Javier Gardeazabal, 2003. "The Economic Costs of Conflict: A Case Study of the Basque Country," American Economic Review, American Economic Association, vol. 93(1), pages 113-132, March.
    16. Pettersson-Lidbom, Per, 2012. "Does the size of the legislature affect the size of government? Evidence from two natural experiments," Journal of Public Economics, Elsevier, vol. 96(3), pages 269-278.
    17. Jeffrey M. Wooldridge, 2003. "Cluster-Sample Methods in Applied Econometrics," American Economic Review, American Economic Association, vol. 93(2), pages 133-138, May.
    Full references (including those not matched with items on IDEAS)


    Citations are extracted by the CitEc Project, subscribe to its RSS feed for this item.

    Cited by:

    1. James G. MacKinnon & Matthew D. Webb, 2020. "When and How to Deal with Clustered Errors in Regression Models," Working Paper 1421, Economics Department, Queen's University.
    2. James G. MacKinnon & Matthew D. Webb, 2017. "Pitfalls When Estimating Treatment Effects Using Clustered Data," Working Paper 1387, Economics Department, Queen's University.
    3. Carvalho, Carlos & Masini, Ricardo & Medeiros, Marcelo C., 2018. "ArCo: An artificial counterfactual approach for high-dimensional panel time-series data," Journal of Econometrics, Elsevier, vol. 207(2), pages 352-380.
    4. Cragun, Randy, 2019. "Effects of lower ages of majority on oral contraceptive use: Evidence on the validity of The Power of the Pill," MPRA Paper 100871, University Library of Munich, Germany, revised 03 Jun 2020.
    5. Martin Huber, 2019. "An introduction to flexible methods for policy evaluation," Papers 1910.00641,
    6. Giovanni Peri & Vasil Yasenov, 2019. "The Labor Market Effects of a Refugee Wave: Synthetic Control Method Meets the Mariel Boatlift," Journal of Human Resources, University of Wisconsin Press, vol. 54(2), pages 267-309.
    7. Victor Chernozhukov & Kaspar Wuthrich & Yinchu Zhu, 2017. "An Exact and Robust Conformal Inference Method for Counterfactual and Synthetic Controls," Papers 1712.09089,, revised Nov 2019.
    8. Bruno Ferman, 2019. "A simple way to assess inference methods," Papers 1912.08772,, revised Aug 2020.
    9. Stearns, Jenna & White, Corey, 2018. "Can paid sick leave mandates reduce leave-taking?," Labour Economics, Elsevier, vol. 51(C), pages 227-246.
    10. Benjamin Bittschi & Nadja Dwenger & Johannes Rincke, 2020. "Water the Flowers You Want to Grow? Evidence on Private Recognition and Donor Loyalty," CESifo Working Paper Series 8424, CESifo.
    11. Bruno Ferman, 2019. "Inference in Differences-in-Differences: How Much Should We Trust in Independent Clusters?," Papers 1909.01782,, revised Sep 2020.
    12. Bruno Ferman, 2020. "Inference in Differences-in-Differences with Few Treated Units and Spatial Correlation," Papers 2006.16997,, revised Aug 2020.
    13. Ferman, Bruno & Pinto, Cristine, 2017. "Placebo Tests for Synthetic Controls," MPRA Paper 78079, University Library of Munich, Germany.
    14. Ferman, Bruno, 2017. "Matching Estimators with Few Treated and Many Control Observations," MPRA Paper 78940, University Library of Munich, Germany.

    More about this item

    JEL classification:

    • C12 - Mathematical and Quantitative Methods - - Econometric and Statistical Methods and Methodology: General - - - Hypothesis Testing: General
    • C21 - Mathematical and Quantitative Methods - - Single Equation Models; Single Variables - - - Cross-Sectional Models; Spatial Models; Treatment Effect Models
    • C33 - Mathematical and Quantitative Methods - - Multiple or Simultaneous Equation Models; Multiple Variables - - - Models with Panel Data; Spatio-temporal Models


    Access and download statistics


    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:fgv:eesptd:406. See general information about how to correct material in RePEc.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: (Núcleo de Computação da FGV EPGE). General contact details of provider: .

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    If CitEc recognized a reference but did not link an item in RePEc to it, you can help with this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service hosted by the Research Division of the Federal Reserve Bank of St. Louis . RePEc uses bibliographic data supplied by the respective publishers.