Calculating the Gini coefficient of regional specialization based on regional industry data (normally employment data)
gini.spec(e_ij, e_i, lc = FALSE, lcx = "% of objects",
lcy = "% of regarded variable", lctitle = "Lorenz curve",
le.col = "blue", lc.col = "black", lsize = 1, ltype = "solid",
bg.col = "gray95", bgrid = TRUE, bgrid.col = "white",
bgrid.size = 2, bgrid.type = "solid", lcg = FALSE, lcgn = FALSE,
lcg.caption = NULL, lcg.lab.x = 0, lcg.lab.y = 1,
add.lc = FALSE, plot.lc = TRUE)
a numeric vector with the employment of the industries
a numeric vector with the employment in the industries
logical argument that indicates if the Lorenz curve is plotted additionally (default: lc = FALSE
, so no Lorenz curve is displayed)
if lc = TRUE
(plot of Lorenz curve), lcx
defines the x axis label
if lc = TRUE
(plot of Lorenz curve), lcy
defines the y axis label
if lc = TRUE
(plot of Lorenz curve), lctitle
defines the overall title of the Lorenz curve plot
if lc = TRUE
(plot of Lorenz curve), le.col
defines the color of the diagonale (line of equality)
if lc = TRUE
(plot of Lorenz curve), lc.col
defines the color of the Lorenz curve
if lc = TRUE
(plot of Lorenz curve), lsize
defines the size of the lines (default: 1)
if lc = TRUE
(plot of Lorenz curve), ltype
defines the type of the lines (default: "solid"
)
if lc = TRUE
(plot of Lorenz curve), bg.col
defines the background color of the plot (default: "gray95"
)
if lc = TRUE
(plot of Lorenz curve), the logical argument bgrid
defines if a grid is shown in the plot
if lc = TRUE
(plot of Lorenz curve) and bgrid = TRUE
(background grid), bgrid.col
defines the color of the background grid (default: "white")
if lc = TRUE
(plot of Lorenz curve) and bgrid = TRUE
(background grid), bgrid.size
defines the size of the background grid (default: 2)
if lc = TRUE
(plot of Lorenz curve) and bgrid = TRUE
(background grid), bgrid.type
defines the type of lines of the background grid (default: "solid"
)
if lc = TRUE
(plot of Lorenz curve), the logical argument lcg
defines if the non-standardized Gini coefficient is displayed in the Lorenz curve plot
if lc = TRUE
(plot of Lorenz curve), the logical argument lcgn
defines if the standardized Gini coefficient is displayed in the Lorenz curve plot
if lcg = TRUE
(displaying the Gini coefficient in the plot), lcg.caption
specifies the caption above the coefficients
if lcg = TRUE
(displaying the Gini coefficient in the plot), lcg.lab.x
specifies the x coordinate of the label
if lcg = TRUE
(displaying the Gini coefficient in the plot), lcg.lab.y
specifies the y coordinate of the label
if lc = TRUE
(plot of Lorenz curve), add.lc
specifies if a new Lorenz curve is plotted (add.lc = "FALSE"
) or the plot is added to an existing Lorenz curve plot (add.lc = "TRUE"
)
logical argument that indicates if the Lorenz curve itself is plotted (if plot.lc = FALSE
, only the line of equality is plotted))
A single numeric value (
The Gini coefficient of regional specialization (gini()
). It represents the degree of regional specialization of the region lc = TRUE
).
Farhauer, O./Kroell, A. (2013): “Standorttheorien: Regional- und Stadtoekonomik in Theorie und Praxis”. Wiesbaden : Springer.
Nakamura, R./Morrison Paul, C. J. (2009): “Measuring agglomeration”. In: Capello, R./Nijkamp, P. (eds.): Handbook of Regional Growth and Development Theories. Cheltenham: Elgar. p. 305-328.
# NOT RUN {
# Example from Farhauer/Kroell (2013):
E_ij <- c(700,600,500,10000,40000)
# employment of five industries in the region
E_i <- c(30000,15000,10000,60000,50000)
# over-all employment in the five industries
gini.spec (E_ij, E_i)
# Returns the Gini coefficient of regional specialization (0.6222222)
# Example Freiburg
data(Freiburg)
# Loads the data
E_ij <- Freiburg$e_Freiburg2014
# industry-specific employment in Freiburg 2014
E_i <- Freiburg$e_Germany2014
# industry-specific employment in Germany 2014
gini.spec (E_ij, E_i)
# Returns the Gini coefficient of regional specialization (0.2089009)
# Example Goettingen
data(Goettingen)
# Loads the data
gini.spec(Goettingen$Goettingen2017[2:16], Goettingen$BRD2017[2:16])
# Returns the Gini coefficient of regional specialization 2017 (0.359852)
# }
Run the code above in your browser using DataLab