/stataguide

Introductory Guide to Using Stata in Empirical Financial Accounting Research

Primary LanguageStataMIT LicenseMIT

Introductory Guide to Using Stata in Empirical Financial Accounting Research

Comments and suggestions are welcome

This repo contains my Stata guide (a pdf book) and the code examples presented in Chapters 4-5 and the Appendices. For the examples in Chapter 4, the Data folder contains several datasets that can be used to replicate the examples.

The objective of this guide is to assist BSc/MSc students, PhD students, and junior researchers in using Stata for empirical archival research. Stata is a powerful program that can be used to analyze many different research questions in the fields of accounting, finance, economics, and beyond. While many statistical packages exist, a major advantage of Stata is that it allows you to carefully manage your data and research process, compute key variables needed in empirical research (e.g., fitted or residual values from a prediction model), and easily merge large sets of data (e.g., combining financial statement data from Compustat with stock market data from CRSP and analyst forecast data from IBES). The purpose of this guide is to give students a head start in using Stata in empirical accounting and finance research settings.

Version history:

  • Version 5.0: September 2023
  • Version 4.1: May 2019
  • Version 4.0: January 2019
  • Version 3.0: December 2013
  • Version 2.0: December 2011
  • Version 1.0: December 2010

New in version 5:

  • Update to Stata 18;
  • Publication of code on Github;
  • Improved and expanded section on standard errors;
  • Improved section of fixed effects estimation;
  • Improved section on matching and added entropy balancing;
  • Added section on robust regression estimators in Chapter 4;
  • Added section on difference-in-differences estimators in Chapter 4;
  • Added section on creating and formatting graphs in Chapter 4;
  • Added a separate chapter on simulations and programming in Chapter 5;
  • Added Appendix on the use of Stata for downloading of data from WRDS;
  • Improved Appendix on implied cost of capital estimation;