Global-Value-Chain Decomposition

Two global-value-chain decompositions are implemented. Firstly, the Wang-Wei-Zhu (Wang, Wei, and Zhu, 2013) algorithm splits bilateral gross exports into 16 value-added components. Secondly, the Leontief decomposition (default) derives the value added origin of exports by country and industry, which is also based on Wang, Wei, and Zhu (Wang, Z., S.-J. Wei, and K. Zhu. 2013. "Quantifying International Production Sharing at the Bilateral and Sector Levels.").


License CRAN Version Total RStudio Cloud Downloads Monthly RStudio Cloud Downloads Travis-CI Build Status Coverage Status

Bastiaan Quast, [email protected]

Two Global Value Chains decompositions are implemented. Firstly, the Wang-Wei-Zhu (Wang, Wei, and Zhu 2013) algorithm splits bilateral gross exports into 16 value added components. Secondly, the Leontief decomposition (default) derives the value added origin of exports by country and industry, which is also based on Wang, Wei, and Zhu (2013).

Additional tools for GVC analysis are available in the gvc package.

Installation

You can install the latest stable version from CRAN.

install.packages("decompr")

The development version, to be used at your peril, can be installed from GitHub using the devtools package.

if (!require('devtools')) install.packages('devtools')
devtools::install_github("bquast/decompr")

Usage

Following installation, the package can be loaded using:

library(decompr)

For general information on using the package, please refer to the help files.

help("decompr")
help(package="decompr")

For examples of usage, see the function specific help pages, in particular the decomp() function.

help("decomp")
help("leontief")
help("wwz")
help("load_tables_vectors")

In addition to the help files we provide a long form example in a vignette .

vignette("decompr")

Additional Information

An overview of the changes is available in the NEWS file.

news(package="decompr")

There is a dedicated website with information hosted on my personal website.

http://qua.st/decompr

Development

Development takes place on the GitHub page.

http://github.com/bquast/decompr

Bugs can be filed on the issues page on GitHub.

https://github.com/bquast/decompr/issues

Credit

The Wang-Wei-Zhu algorithm (wwz())is based on R code written by Fei Wang (not to be confused with the author of the algorithm, with the same last name), which implemented this algorithm.

References

Wang, Zhi, Shang-Jin Wei, and Kunfu Zhu. 2013. “Quantifying International Production Sharing at the Bilateral and Sector Levels.”

News

decompr 4.5.0

  • code refactoring\

  • added v

decompr 4.1.0

  • fix post multiplication "final_demand" of leontief()

decompr 4.0.0

  • add post-multiplication argument to leontief method

  • remove leontief_output(), functionality moved to leontief()

  • use ellipsis for decomp function

decompr 3.0.0

  • remove vertical_specialisation and vertical_specialization, will be included in gvc package

  • add some attributes to output t.b. used by gvc package

  • change the output format of leontief and leontief-output to long form (tidy data)

  • add columns country and sectors names

  • add DViX_Fsr to wwz

  • add Vignette (decompr)

  • add tests

  • add Travis-CI support

  • add coveralls.io support

decompr 2.1.0

  • add a leontief_output decomposition method

  • update the README.md file

  • add warning when no method is specified in decomp (default is Leontief as of v.2)

decompr 2.0.0

  • make load_tables_vectors default

  • change notice to reflect new default

  • update examples and data to reflect lt

  • replace use of 2 dimensional arrays with matrices

  • more efficient construction of rownam and z1

  • replace use of length(k) with G

  • replace use of various inefficient uses of diag() (e.g. with Vhat)

  • improved spacing of code for legibility

  • make leontief default method

decompr 1.3.2

  • add notice

decompr 1.3.1

  • fix citations etc.

decompr 1.3.0

  • add load_tables_vectors to input in simple form

decompr 1.2.1

  • update authors

decompr 1.2.0

  • update citation code

  • use " in stead of ' in examples and function arguments

  • use match.arg for method in decomp function

decompr 1.1.0

  • update references

  • include more descriptive description

decompr 1.0.2

  • update example data to regional tables for faster computations

  • put back examples for non-decomp functions

decompr 1.0.1

  • remove examples other than for decomp function, to pass CRAN test in time

  • add cran-comments.md

decompr 1.0.0

  • functions names use underscores in stead of periods

  • method names use underscores in stead of periods

  • examples reflect the above changes

  • WIOD data set is now compressed using bzip2

  • included this news file

decompr 0.7.0

  • citation information is included

decompr 0.6.0

  • example data set in included

decompr 0.5.0

  • examples are included

Reference manual

It appears you don't have a PDF plugin for this browser. You can click here to download the reference manual.

install.packages("decompr")

4.5.0 by Bastiaan Quast, 3 years ago


http://qua.st/decompr, https://github.com/bquast/decompr


Report a bug at https://github.com/bquast/decompr/issues


Browse source code at https://github.com/cran/decompr


Authors: Bastiaan Quast [aut, cre] , Fei Wang [aut] , Victor Kummritz [aut] , Oliver Reiter [ctb]


Documentation:   PDF Manual  


Task views: Econometrics


GPL-3 license


Suggests gvc, testthat, knitr


Imported by gvc, wiod.


See at CRAN