This R package, documented in a very similar way to the book R4DS, provides functions to replicate the original Stata results from the book An Advanced Guide to Trade Policy Analysis.
For the analysis, this provides functions to compute robust clustered standard errors in generalized linear models. See https://r.tiid.org/R_structural_gravity/ for a fully detailed replication of AGTPA's results.
install.packages("tradepolicy")
# install.packages("remotes")
remotes::install_github("pachamaltese/tradepolicy")
If you use tradepolicy
in academic works or other publication, please cite as follows:
Mauricio Vargas (2020). tradepolicy: An Advanced Guide to Trade Policy Analysis. R
package version 0.2. https://pacha.dev/tradepolicy/
BibTeX entry:
@Manual{,
title = {tradepolicy: Replication of 'An Advanced Guide To Trade Policy Analysis'},
author = {Mauricio Vargas},
year = {2021},
note = {R package version 0.4.1},
url = {https://pacha.dev/tradepolicy/},
doi = {10.5281/zenodo.4277741}
}