leontief: Leontief Decomposition

View source: R/leontief.R

leontiefR Documentation

Leontief Decomposition

Description

The Leontief decomposition of gross flows (exports, final demand, output) into their value added origins.

Usage

leontief(x, post = c("exports", "output", "final_demand", "none"), long = TRUE)

Arguments

x

an object of class decompr.

post

post-multiply the value added multiplier matrix [VB = V(I-A)^{-1}] with something to deduce the value added origins thereof. The default is "exports" VAE = V(I-A)^{-1}E, where E is a diagonal matrix with exports along the diagonal yielding the country-industry level sources of value added (rows) for each using (column) country-industry; similarly for "output". Option "final_demand" computes value added origins of final demand by source country-industry and importing country, by computing VAY = V(I-A)^{-1}Y where Y is the corresponding GN x G matrix contained in x. Option "none" just returns VB which gives the value added shares.

long

logical. Transform the output data into a long (tidy) data set or not, default is TRUE.

Details

The Leontief decomposition is obtained by pre-multiplying the flow measure (e.g. exports) with the value added multiplier matrix [VB = V(I-A)^{-1}], obtained by pre-multiplying the Leontief Inverse matrix [B = (I-A)^{-1}] with a diagonal matrix [V] containing the direct value added share in each industries output.

V is obtained as diag(v / o) where o is total industry output. v is either supplied to load_tables_vectors or computed as o - colSums(x) with x the raw IO matrix. If o is not supplied to load_tables_vectors, it is computed as rowSums(x) + rowSums(y) where y is the matrix of final demands. If both o and v are not supplied to load_tables_vectors, this is equivalent to computing V as diag(1 - colSums(A)), with A is the row-normalized IO matrix also used to compute the Leontief Inverse [B].

Value

If long = TRUE a molten data frame containing the elements of the decomposed flows matrix in the final column, preceded by several identifier columns. If long = FALSE the decomposed flows matrix is simply returned.

Author(s)

Bastiaan Quast

References

Leontief, W. (Ed.). (1986). Input-output economics. Oxford University Press.

Hummels, D., Ishii, J., & Yi, K. M. (2001). The nature and growth of vertical specialization in world trade. Journal of international Economics, 54(1), 75-96.

Wang, Zhi, Shang-Jin Wei, and Kunfu Zhu (2013). Quantifying international production sharing at the bilateral and sector levels (No. w19677). National Bureau of Economic Research.

See Also

kww, wwz, decompr-package

Examples

# Load example data
data(leather)

# Create intermediate object (class 'decompr')
decompr_object <- load_tables_vectors(leather)

# Perform the Leontief decomposition of each country-industries 
# exports into their value added origins by country-industry
leontief(decompr_object)

decompr documentation built on June 19, 2022, 5:06 p.m.