Skip to main content

WiNDC Paper Tutorial (Leakage Model)

In this tutorial you will learn how to reproduce the results of the WiNDC paper using WiNDC 2.0. In the first part of the paper, the authors describe how to construct the core WiNDC dataset and modeling environment. In the second part, they introduce the energy-environment module and use it to analyse the effectiveness of policies that aim to reduce carbon emissions.

Overview

Suppose one US state introduces measures to decrease carbon emissions. These measures will make the production of energy-intensive goods more expensive compared to production in states that do not regulate emissions. Therefore a part of the production of energy-intensive goods may shift to unregulated states. Thus the reduction of carbon emissions in one state may lead to an increase of carbon emissions in other states. This is known as carbon leakage. The level of carbon leakage determines how effective subnational climate policies are in reducing emissions country-wide.

We analyse seven different subnational climate policies; they are listed in Table 9 in the paper. Each policy covers a selection of states. We assess the level of leakage resulting from a 20% decrease in carbon emissions in the states covered by the respective climate policy.

The model has three sensitivity parameters: trade flows, carbon permit trade and production structure.

  1. Trade flows. Trade flows between US states (i.e. regions) are modeled either by explicit bilateral trade flows for each sector and between each region by a gravity estimation routine or as a pooled national market (the approach of the canonical WiNDC system).
  2. Carbon permit trade. Carbon permits impose the carbon limit. They are assumed to be tradable across sectors within a region. In addition, permits are either tradable between states (covered by the same policy) or not.
  3. Production structure. Production is modeled either by the production structure of the canonical WiNDC system (see Figure 5 in the paper) or an alternative structure. The alternative structure modifies the canonical form by embedding energy based substitutions using a "KLEM" (capital, labor, energy and materials) production function (see Figure 11 in the paper).

There are eight configurations of the sensitivity parameters. Thus we run eight variants of the model for each of the seven policies.

Technical Requirements

A valid GAMS license.
The code is platform independent.

Downloads

Download the leakage build package. The zip file contains the directory leakage. This directory has two subdirectories: build and model.

Note

We will call the file WiNDC_cal_2016_bluenote.gdx "bluenote file". The bluenote file contains the dataset for the energy-environment module for the year 2016. It was generated from the core WiNDC 2.0 dataset as described here. The bluenote file is part of the leakage build package: it is located in the subdirectory data of the directory build.

Acknowledgements

We thank Andrew Schreiber for generously making his code available. Note that the version we use is a slightly updated version compatible with WiNDC 2.0. You can find the original version of the files here.

Generate the Data for the Model Runs

The downloaded zip file contains the directory leakage with the subdirectories build and model. The directory build contains the input data and GAMS files that generate the data for the model runs. The directory model contains the routines for the model runs.

The input data file for the model runs is called WiNDC_bluenote_2016_leakage.gdx. We will call this file "leakage file". The leakage file is generated using the data and GAMS files in the subdirectory build. The file databuild.gms loads the bluenote file, calls various routines and generates the leakage file. Run the file databuild.gms with the following command:

gams databuild.gms

Note that the file databuild.gms cannot run successfully without the bluenote file.
The leakage file will be generated and saved in the the subdirectory data of the directory model. Details of the parameters and sets in the leakage file are given here.

Model Runs

The models are run in the directory model. This directory has two subdirectories: data and output. The subdirectory data contains the leakage file (WiNDC_bluenote_2016_leakage.gdx). The leakage file is the data input file for all model runs. If the leakage file is missing from your data directory, you need to run the file databuild.gms as described in the previous step. The subdirectory output serves as storage for the output files of the model runs.

Run the file run.gms:

gams run.gms

This will take ca. 25 minutes and automatically runs all model instances. The file run.gms calls three GAMS files:

  1. The file genruns.gms generates the file modelruns.gms.
  2. The file modelruns.gms calls the file leakagemodel.gms for each of the eight scenarios. In addition, it runs the file statepolicy.gms for all eight scenarios and and seven climate policies. The sensitivity parameters are defined with double dash parameters in the GAMS calls. Further, other scenarios with different percentages of carbon emissions reductions are run. The listing files of all these GAMS runs are saved in the subdirectory lst of the directory output.
  3. The file results.gms compiles the results of the runs of leakagemodel.gms into the GDX file results.gdx in the directory output. The results of the runs of statepolicy.gms are saved in the GDX files in the subdirectory gdx of the output directory.

In addition to these three GAMS files, the file run.gms optionally runs the R script results.r. This script generates tables with results that can be included in LaTeX files. The tables are saved in the subdirectory tex of the directory output.