Skip to content

benjaminengst/ScalingCourtDecisions

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Scaling Courts with Citation Networks

Project Team

Setup

For interoperability with the data base that was indexed with ElasticSearch, we were using first Python, and then R and STAN. Since multiple languages may easily cause a headache, we did our best in being as consistent as possible:

  • We use R as a wrapper to run the whole code. AEG_replication_master.r will generate all figures and tables from scratch.
  • All data management up to the data for estimation is implemented in Python. The antitrust case is a bit of an exception, since it used the Juris frontend.
  • Once all data for estimation is written, R takes over.
  • We implemented the bayesian estimation with STAN.

For more information on the overall structure of the code, please see the section on the Code below.

Python Environment

We suggest you create a python environment that looks just like ours. The necessary information for the relevant libraries can be found in the file environment.yml. If you need further help, the conda documentation is your friend.

You can create the environment from AEG_slc.yml

      conda env create -f AEG_slc.yml

And then activate the new environment:

      conda activate AEG_slc

For calling Python from within R, the reticulate documentation will offer a good introduction. Don't forget to adapt the python path to your conda environment in the project-.Rprofile.

R Environment

Code

The whole replication files will run from beginning to the end via executing AEG_replication_master.r. It will

  • read in the pickles;
  • generate .csvs for estimation;
  • estimate the models;
  • generate results;
  • implement posterior predictive checks.

All files are relative to AEG_replication_master.r. You can run it

  • via RStudio: Open replication_AEG.Rproj. RStudio then sets the correct working directory;
  • from Terminal: Make sure to set the working directory as fit.

Questions?

For all questions regarding the code, feel free to reach out to Chris Arnold.

About

Replication data for Arnold / Engst / Gschwend. 2023. "Scaling Court Decisions with Citation Networks." Journal of Law and Courts (First View): 1 - 20.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • HTML 94.2%
  • R 4.6%
  • Other 1.2%