IDEAS home Printed from
   My bibliography  Save this paper

Using Stata for a memory saving fixed effects estimation for the three-way error component model


  • Cornelißen, Thomas


"The paper proposes a memory saving decomposition of the design matrix to facilitate fixed effects estimation of the three-way error component model with high numbers of observations and groups. A common way to estimate such a model is to include two of the effects as dummy variables and to sweep out the other effect by the fixed effects trans-formation. If the number of groups is high, the design matrix that includes the dummy variables can be prohibitively large for computer packages that need to store the whole data set in memory. The decomposition of the design matrix proposed here shows a way of how to create the cross-product matrices for the least squares normal equations without explicitly creating the dummy variables for the group effects. As the cross-product matrices are of much lower dimension than the design matrix, this procedure reduces the computer memory required considerably. For example, a model computation shows that in a linked employer-employee data set with 20 million observations and 10 thousand firms, the memory requirement drops from 800 gigabytes to 1 gigabyte. The method is implemented in Stata by making use of the new Mata environment available in Stata 9.0. Besides implementing the memory-saving estimation method, the program also takes care of identification issues (grouping algorithm) and provides useful summary statistics. The paper presents the Stata program and comments its output." (Author's abstract, IAB-Doku) ((en)) Additional Information The Stata programs can be installed either by typing 'net search felsdvreg' or per download from

Suggested Citation

  • Cornelißen, Thomas, 2006. "Using Stata for a memory saving fixed effects estimation for the three-way error component model," FDZ Methodenreport 200603_en, Institut für Arbeitsmarkt- und Berufsforschung (IAB), Nürnberg [Institute for Employment Research, Nuremberg, Germany].
  • Handle: RePEc:iab:iabfme:200603_en

    Download full text from publisher

    File URL:
    Download Restriction: no


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

    Cited by:

    1. Davidson, Carl & Heyman, Fredrik & Matusz, Steven & Sjöholm, Fredrik & Zhu, Susan Chun, 2014. "Globalization and imperfect labor market sorting," Journal of International Economics, Elsevier, vol. 94(2), pages 177-194.
    2. C. Kirabo Jackson & Elias Bruegmann, 2009. "Teaching Students and Teaching Each Other: The Importance of Peer Learning for Teachers," American Economic Journal: Applied Economics, American Economic Association, vol. 1(4), pages 85-108, October.
    3. Martin Chalkley & Colin Tilley & Shaolin Wang, 2011. "Comparing the treatment provided by migrant and non-migrant health professionals: dentists in Scotland," Dundee Discussion Papers in Economics 249, Economic Studies, University of Dundee.

    More about this item


    IAB-Linked-Employer-Employee-Datensatz; Datenanalyse; Software; Algorithmus; Schätzung;

    JEL classification:

    • C23 - Mathematical and Quantitative Methods - - Single Equation Models; Single Variables - - - Models with Panel Data; Spatio-temporal Models
    • C63 - Mathematical and Quantitative Methods - - Mathematical Methods; Programming Models; Mathematical and Simulation Modeling - - - Computational Techniques


    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:iab:iabfme:200603_en. 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: (IAB, Geschäftsbereich Dokumentation und Bibliothek). 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.

    We have no references for this item. You can help adding them by using 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.