Skip to content

Tariff Line Module


The GTAP data base offers bi-lateral protection and matching trade flow data based on MacMaps at the level of 57 GTAP sectors which are often further aggregated in model applications. That implies that information on protection measures at tariff line, which might also comprise complex instruments such as Tariff Rate Quotas (TRQs), needs to be aggregated to GTAP sector level and beyond. That might provoke aggregation bias (cf. Himics and Britz 2016). Analysis especially of (potential) Free Trade Agreements requires often detail beyond the 57 sectors of GTAP. The module for CGEBox described in here allows detail at tariff line for selected bi-lateral trade links and commodities while maintaining otherwise the chosen default trade structure for that sector (Armington or Armington plus CET, a combination with the Melitz module is currently not supported). If a MCP solver is available, multiple TRQs at bi-lateral tariff line can be introduced such that applied tariff rates become endogenous. At the same time, the structure provides a fully consistent aggregation from tariff line to commodity level.

The demand representation is based on a three-tier representation: (1) top level demand function such as the CDE in the GTAP standard, (2) First Armington nest between domestic sales and aggregate imports, (3) Bi-lateral Armington nest). A similar structure is found for supply transformation when the CET extensions is used: (1) first CET nest between domestic sales and aggregate exports, (2) CET nest between bi-lateral exports). Splitting up to tariff line level at the bi-lateral trade flow level as the lowest level of the demand system and supply transformation tree might seem odd at first look. One would perhaps rather like to split demand, for instance of dairy, first to tariff lines such as butter, cheese etc. , next determine how much butter etc. is stemming from the home market and from imports, and finally how butter imports are composed from different importers. However, introducing the dis-aggregation and thus the new nest with tariff line information directly below the top level nests requires firstly introducing the tariff line split up for all bi-lateral trade flows of a region, and if a CET application is used, also for all its exporters and thus most probably for all regions in the model. That quickly renders the model quite large. Secondly, data on domestic sales at tariff line level must be available, data which are not generally available.

The proposed approach which rather split below the lowest level thus dramatically reduces data needs as it requires tariff line information on trade flows and protection data only for some bi-lateral links, namely those in the focus of the analysis. Data on domestic sales at tariff lines are not needed at all. Furthermore, it keeps the model at a manageable size even if some bi-lateral trade flows are depicted with rich dis-aggregated tariff line information. That is especially important if TRQs are modelled which requires a MCP solver which typically is slower compared to solving a simple non-linear equation system.


The user has to apply the following information:

  • The set of tariff lines considered and their mapping to the GTAP sectors in the data base used by for model run

  • Information on trade for selected bi-lateral trade flows at tariff line level. A bi-lateral trade flow for a commodity will only be depicted at tariff line level in the model when at least one non-zero flows for one tariff line is found. Otherwise, the bi-lateral commodity flow will continue to use the chosen default trade representation for that commodity without a dis-aggregation to tariff line.

  • Matching applied tariff or TRQs with in- and out-of-quota rates.

Based on that information, the code will add the necessary equations and variables for the selected trade links, fit the data to the given benchmark and introduce matching parameters.

Note again that Melitz extension cannot be combined with the tariff line module for a product.

Model equations

The code for the tariff line sub-module can be found in the sub-directory “gams\tariffLines”. The equations and core definition are found in “tariffLines_model.gms”.

The code of the model comprises four equations:

  • Two equations which define the bi-lateral exports and imports at tariff line level

  • And two matching dual price aggregators which define the bi-lateral export and import prices at the level of GTAP commodities at bi-lateral level.

The bilateral export supply equation is shown below:

The parameter p_wgtl depicts the share of the tariff line tl in total bi-lateral trade of commodity i shipped from exporter rNat to importer rNat1. The equation is hence only introduced if a share parameter was defined during calibration, i.e. for such bi-lateral trade flows where information on that tariff line was provided.

Note that the variable pe, the bi-lateral export price, is part of the standard model when non-infinite CET is used while the price at the tariff line level ptls is not. Note equally that in the standard layout, bi-lateral export and import quantities at commodity level xw are by definition equal as they are no quality differences considered at that level without tariff line detail. That is no longer the case when the additional CES and CET nests at tariff line level are active such that the bi-lateral export quantity is now depicted by xws as a CET aggregate over tariff line. It is only identically to xw in the benchmark, in a simulation, the (implicit) non-linear aggregation based on the CES and CET will let the aggregate supply and demand quantities deviate.

The average import price is defined as follows:

Where gw is the share parameter in the second level CET nest.

In the original layout, the export price pe is implicitly defined by the equation peeq which defines xw from total export supply. To keep that equation untouched, it is replaced here by a variant which is used if NO tariff line equation is given. Beside the related $ condition, it is identical to the equation in the standard model:

The bi-lateral export supply at commodity level xws is defined identically, however neglecta the case of small import shares or infinite transformation:

The demand side comprises similar equations, first to define bi-lateral import demand at tariff line level xwtl (which by definition is equal to export supply):

The macro m_pmcifTl define the cif price, to which tariff line specific tariff imptxTL are added as well as potentially a general shifter for import taxation of product i. Note that imptxTL is defined as a variable to render it endogenous under a TRQ. The macro is based itself on a macro to define the f.o.b. price:

Both macros are identically structured as the macros in the standard model. Note that export taxes are currently not differentiated at tariff line level and that the trade margins are also assumed to be identical for all tariff lines belonging to the same commodity.

The average bi-lateral import price pm for a commodity i, normally substituted out in the standard model with the m_pmcif macro, is in here explicitly defined as an aggregation over the tariff-line prices:

To keep the standard model simple, the modified xw equation e_xwMod which distinguishes between the case of dis-aggregation to tariff line or not is only comprised in the sub-module model:

Finally, there is an equation for the TRQ mechanism:

The TRQ equation clearly requires that the related tariff at tariff line level imptxTL is endogenous and not fixed. With a MCP solver, bounds on that tariff variable model can depict the regime switch from under-filled quota (= tariff at lower bound) to binding quota (= tariff between lower and upper bound, the tariff variable is equal to the per unit quota rent plus the in-quota tariff) and over-quota imports (= tariff at upper bound). Note that introducing TRQs with a CNS solver will only work for the cases where the quota is binding in the benchmark and the simulation, i.e. the implicite tariff is between its lower and upper bounds in the final solution.

Entering the data

The user provided data are stored in files in the directory “gams\scen\tariffLine”. A trial implementation to model EU->CAN exports at tariff line level can be found there as “ceta.gms”. It fits any data base with at least EU28, USA and ROW as labels for regions and “mil” and “wht” as commodities.

Note that the information provided by such a file to module needs to be broken up in two blocks:

  1. The declarations, i.e. the set of considered tariff lines and how they are mapped to the GTAP commodities in the current aggregation:

Note that the set of tariff lines tl and there link to the commodity tl_i must be defined in block in a $ifthen-else-endif structure as shown above.

  1. The actual data and parameter to use

Note that the data above are invented and the tariff randomly drawn to provide a test framework for the module. The data to use need to be stored in “gams\scen\tariffline” and can from there selected via the GUI (see below).


The bi-lateral trade flow and protection data are scaled to match the information in the global SAM in the file “gams\tariffLines\tariffLines_cal.gms”

As export subsidies are assumed to be identical across tariff lines, the tariff line price at the benchmark is equal to the average export price:

Such that the share parameters can be derived directly from the quantities:

That is not the case for the importer side where tariff differentiation is assumed at tariff line level:

Post model processing

The code comprising the model equations also comprises a section for post-model processing:

Integration in the GUI

Model configuration

The module can as usually be switched on under the “Model structure” tab:

Note again that a non-default parameter file must be chosen which introduces transformation elasticities. It is not possible to use the model with an infinite transformation elasticity between export destinations.

The file with the set of considered tariff lines and related data can be chosen on the “Tariff lines” tab:

Result exploitation

The results at tariff line level are comprised in the two tables “Exports, trade matrix, Tariff lines” and “Imports, trade matrix, Tariff lines”:

A screen shot of a part of such a table is shown below:


Himics, M., Britz, W. (2016): Flexible and welfare-consistent tariff aggregation over exporter regions, Economic Modelling 53: 375-387