IDEAS home Printed from https://ideas.repec.org/a/bpj/jecome/v5y2016i1p143-152n4.html
   My bibliography  Save this article

An Algorithm to Estimate the Two-Way Fixed Effects Model

Author

Listed:
  • Somaini Paulo

    () (Department of Economics, MIT, Cambridge, MA, USA)

  • Wolak Frank A.

    (Department of Economics, Stanford University, Stanford, CA, USA)

Abstract

We present an algorithm to estimate the two-way fixed effect linear model. The algorithm relies on the Frisch-Waugh-Lovell theorem and applies to ordinary least squares (OLS), two-stage least squares (TSLS) and generalized method of moments (GMM) estimators. The coefficients of interest are computed using the residuals from the projection of all variables on the two sets of fixed effects. Our algorithm has three desirable features. First, it manages memory and computational resources efficiently which speeds up the computation of the estimates. Second, it allows the researcher to estimate multiple specifications using the same set of fixed effects at a very low computational cost. Third, the asymptotic variance of the parameters of interest can be consistently estimated using standard routines on the residualized data.

Suggested Citation

  • Somaini Paulo & Wolak Frank A., 2016. "An Algorithm to Estimate the Two-Way Fixed Effects Model," Journal of Econometric Methods, De Gruyter, vol. 5(1), pages 143-152, January.
  • Handle: RePEc:bpj:jecome:v:5:y:2016:i:1:p:143-152:n:4
    as

    Download full text from publisher

    File URL: https://www.degruyter.com/view/j/jem.2016.5.issue-1/jem-2014-0008/jem-2014-0008.xml?format=INT
    Download Restriction: For access to full text, subscription to the journal or payment for the individual article is required.

    As the access to this document is restricted, you may want to search for a different version of it.

    References listed on IDEAS

    as
    1. Sergio Correia, 2014. "REGHDFE: Stata module to perform linear or instrumental-variable regression absorbing any number of high-dimensional fixed effects," Statistical Software Components S457874, Boston College Department of Economics, revised 18 Nov 2019.
    2. John M. Abowd & Francis Kramarz & David N. Margolis, 1999. "High Wage Workers and High Wage Firms," Econometrica, Econometric Society, vol. 67(2), pages 251-334, March.
    3. Amine Ouazad, 2008. "A2REG: Stata module to estimate models with two fixed effects," Statistical Software Components S456942, Boston College Department of Economics.
    4. Paulo Guimarães & Pedro Portugal, 2010. "A simple feasible procedure to fit models with high-dimensional fixed effects," Stata Journal, StataCorp LP, vol. 10(4), pages 628-649, December.
    5. Jeffrey M Wooldridge, 2010. "Econometric Analysis of Cross Section and Panel Data," MIT Press Books, The MIT Press, edition 2, volume 1, number 0262232588, September.
    6. Anabela Carneiro & Paulo Guimarães & Pedro Portugal, 2012. "Real Wages and the Business Cycle: Accounting for Worker, Firm, and Job Title Heterogeneity," American Economic Journal: Macroeconomics, American Economic Association, vol. 4(2), pages 133-152, April.
    Full references (including those not matched with items on IDEAS)

    Citations

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


    Cited by:

    1. Eugenio J. Miravete & Katja Seim & Jeff Thurk, 2020. "One Markup to Rule Them All: Taxation by Liquor Pricing Regulation," American Economic Journal: Microeconomics, American Economic Association, vol. 12(1), pages 1-41, February.
    2. Eugenio J. Miravete & Katja Seim & Jeff Thurk, 2018. "Market Power and the Laffer Curve," Econometrica, Econometric Society, vol. 86(5), pages 1651-1687, September.
    3. Frank R. LICHTENBERG, 2018. "The Impact of New Drug Launch on Life-Years Lost in 2015 from 19 Types of Cancer in 36 Countries," JODE - Journal of Demographic Economics, Cambridge University Press, vol. 84(3), pages 309-354, September.
    4. Kleiner, Samuel A., 2019. "Hospital treatment and patient outcomes: Evidence from capacity constraints," Journal of Public Economics, Elsevier, vol. 175(C), pages 94-118.
    5. Jiyong Eom & Frank A. Wolak, 2020. "Breaking Routine for Energy Savings: An Appliance-level Analysis of Small Business Behavior under Dynamic Prices," NBER Working Papers 27263, National Bureau of Economic Research, Inc.
    6. Song, Haiyan & Xie, Karen & Park, Jinah & Chen, Wei, 2020. "Impact of accommodation sharing on tourist attractions," Annals of Tourism Research, Elsevier, vol. 80(C).

    Most related items

    These are the items that most often cite the same works as this one and are cited by the same works as this one.
    1. Mion, Giordano & Opromolla, Luca David, 2014. "Managers' mobility, trade performance, and wages," Journal of International Economics, Elsevier, vol. 94(1), pages 85-101.
    2. Head, Keith & Mayer, Thierry, 2014. "Gravity Equations: Workhorse,Toolkit, and Cookbook," Handbook of International Economics, in: Gopinath, G. & Helpman, . & Rogoff, K. (ed.), Handbook of International Economics, edition 1, volume 4, chapter 0, pages 131-195, Elsevier.
    3. Giordano Mion & Luca David Opromolla & Alessandro Sforza, 2016. "The Diffusion of Knowledge via Managers' Mobility," CEP Discussion Papers dp1458, Centre for Economic Performance, LSE.
    4. Bombardini, Matilde & Orefice, Gianluca & Tito, Maria D., 2019. "Does exporting improve matching? Evidence from French employer-employee data," Journal of International Economics, Elsevier, vol. 117(C), pages 229-241.
    5. Gaure, Simen, 2014. "Practical Correlation Bias Correction in Two-way Fixed Effects Linear Regression," Memorandum 21/2014, Oslo University, Department of Economics.
    6. Cardoso, Ana Rute & Guimaraes, Paulo & Portugal, Pedro & Reis, Hugo, 2018. "The Returns to Schooling Unveiled," IZA Discussion Papers 11419, Institute of Labor Economics (IZA).
    7. Laurent Bergé, 2018. "Efficient estimation of maximum likelihood models with multiple fixed-effects: the R package FENmlm," CREA Discussion Paper Series 18-13, Center for Research in Economic Analysis, University of Luxembourg.
    8. Mario Larch & Joschka Wanner & Yoto V. Yotov & Thomas Zylkin, 2017. "The Currency Union Effect: A PPML Re-assessment with High-Dimensional Fixed Effects," CESifo Working Paper Series 6464, CESifo.
    9. Pedro Portugal, 2020. "The sources of wage variability in Portugal: a binge reading survey," Economic Bulletin and Financial Stability Report Articles and Banco de Portugal Economic Studies, Banco de Portugal, Economics and Research Department.
    10. Mario Macis & Fabiano Schivardi, 2016. "Exports and Wages: Rent Sharing, Workforce Composition, or Returns to Skills?," Journal of Labor Economics, University of Chicago Press, vol. 34(4), pages 945-978.
    11. P. Charnoz & C. Lelarge & C. Trevien, 2016. "Communication Costs and the Internal Organization of Multi-Plant Businesses: Evidence from the Impact of the French High-Speed Rail," Documents de Travail de l'Insee - INSEE Working Papers g2016-02, Institut National de la Statistique et des Etudes Economiques.
    12. Sandra Cavaco & Patricia Crifo & Antoine Rebérioux & Gwenaël Roudaut, 2014. "Independent directors: less informed, but better selected? New evidence from a two-way director-firm fixed effect model," EconomiX Working Papers 2014-58, University of Paris Nanterre, EconomiX.
    13. Nilsen, Øivind Anti & Raknerud, Arvid & Skjerpen, Terje, 2011. "Using the Helmert-transformation to reduce dimensionality in a mixed model: Application to a wage equation with worker and firm heterogeneity," Discussion Paper Series in Economics 11/2011, Norwegian School of Economics, Department of Economics, revised 04 Oct 2011.
    14. Beestermöller, Matthias & Disdier, Anne-Célia & Fontagné, Lionel, 2018. "Impact of European food safety border inspections on agri-food exports: Evidence from Chinese firms," China Economic Review, Elsevier, vol. 48(C), pages 66-82.
    15. Zsolt Csáfordi & László Lőrincz & Balázs Lengyel & Károly Miklós Kiss, 2020. "Productivity spillovers through labor flows: productivity gap, multinational experience and industry relatedness," The Journal of Technology Transfer, Springer, vol. 45(1), pages 86-121, February.
    16. Andrews, M.J. & Gill, L. & Schank, T. & Upward, R., 2012. "High wage workers match with high wage firms: Clear evidence of the effects of limited mobility bias," Economics Letters, Elsevier, vol. 117(3), pages 824-827.
    17. Eppinger, Peter S., 2019. "Service offshoring and firm employment," Journal of International Economics, Elsevier, vol. 117(C), pages 209-228.
    18. Gassebner, Martin & Bluhm, Richard & Langlotz, Sarah & Schaudt, Paul, 2016. "Fueling Conflict? (De)Escalation and Bilateral Aid," VfS Annual Conference 2016 (Augsburg): Demographic Change 145755, Verein für Socialpolitik / German Economic Association.
    19. Picchio, Matteo & van Ours, Jan C., 2016. "Gender and the effect of working hours on firm-sponsored training," Journal of Economic Behavior & Organization, Elsevier, vol. 125(C), pages 192-211.
    20. Richard Upward & Peter Wright, 2015. "Don’t Look Down: New Evidence on Job Loss in a Flexible Labour Market," Discussion Papers 2015-10, University of Nottingham, GEP.

    More about this item

    Statistics

    Access and download statistics

    Corrections

    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:bpj:jecome:v:5:y:2016:i:1:p:143-152:n:4. 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: (Peter Golla). General contact details of provider: https://www.degruyter.com .

    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.