Skip to content

Projects and Homeworks for Applied Econometrics 3 course

Notifications You must be signed in to change notification settings

jpmvbastos/AppliedEconometrics

Repository files navigation

Applied Econometrics

This repository contains codes for projects and homework for courses Applied Econometrics 3 (AAEC6317) and Demand and Price Analysis (AAEC63) at Texas Tech University.

Some of these codes are incomplete and should not be considered as a source of educational material other than providing suggestions on how to implement the relevant models in Stata and Python.

General Files

MonteCarlo_Simulations.ipynb applies common econometrics techniques to data-generating processes under the standard assumptions for Gauss-Markov theorem, as well as when those are violated: endogeneity, heteroskedasticity, auto-correlation.

Applied Econometrics III

Labs

Maximum_Likelihood.do implements maximum likelihood estimators (multinomial logit mlogit, conditional logit asclogit, and nested logit nlogit) using Stata and the Fishing.xls dataset.

GMM.do includes examples for the application of the Generalized Method of Moments estimator, using Stata's gmm.

Homework1.ipynb applies Maximum Likelihood techniques to different data generating processes, also relying on Stata for some estimations. The file Homework1.do has the replication code for Stata, which includes:

  • Estimation of Box-Cox demand using boxcox, and using the user-inputted expression method for Maximum Likelihood Estimation (mlexp).
  • Finite Mixture Models: fmm.

Replication data:

Question 1: data_1.xlsx.

Question 2: data_2.xlsx.

Maximum Likelihood estimations with marginal effects in Stata for discrete choice models and censored regressions, including:

  • Multinomial Logit using mlogit
  • Alternative-specific conditional logit using asclogit
  • Nested logit using nlogit
  • Truncated and censored regressions under a variety of functional forms using tobit,truncreg, nbreg, and poisson.
  • Heckman's selection model using heckman

The assignment and related datasets are described in Homework.pdf and available at the folder.

Includes exercises in Time Series using Python and Matlab.

Using Matlab:

Using Python:

  • Basic autocorrelation and stationarity analysis (Dickey-Fuller, Ljung-Box, etc.)
  • Autoregressive (AR) models
  • Conditional Heteroskedasticity models (ARCH, GARCH)

A rough draft where I use Fixed Effects and Maximum Likelihood Estimators to investigate whether corruption is more harmful to female-led businesses.

Using firm-level data from the World Bank Enterprise Surveys with around 130,000 observations in 133 countries, I ask whether female businesses are more likely to pay bribes and whether they report corruption as a bigger obstacle than their male counterparts.

An improved version of this project (with Dr. Jamie Bologna Pavlik) using Propensity Score Matching and Mahalanobis Distance Matching is available at SSRN.

Estimates demand models using Stata's nlsur (Non-Linear Seemingly Unrelated Regression) function.

  • Lab.do contains the main code. Other files in the folder contain templates for applying the AIDS model in R and Stata.
  • labdata_2023.csv is the data sample used.

Includes some resources for estimating an EASI model in R, Python, and Stata.

Questions include applications of nlsur and quaidsfunctions. These can be used as templates for creating user-specified programs for demand estimation.

Replicates the differences-in-differences analysis from Card & Krueger (1994) and applies clustered wild bootstrap methods for inference using boottest.

About

Projects and Homeworks for Applied Econometrics 3 course

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages