World inequality

Description

Purpose of the App is present the evolution of the Gini coefficients of income inequality.

Data comes from Bruegel, as of 06 April 2021.

Data source: Darvas, Zsolt (2019) 'Global interpersonal income inequality decline: the role of China and India', World Development, Volume 121, September 2019, Pages 16-32.

Data are fetched to a data template in real time through rejustify.

Repository details: REJUSTIFY/BRUEGEL-GINI

Developed and hosted by rejustify.com
Data at the courtesy of Bruegel

Deployed with Shiny



Loading...
Loading...
Loading...

            

Package install and load

install.packages("remotes")
remotes::install_github("rejustify/r-package")
library(rejustify)

Authenticate

Create your free acount.

setCurl()
register(token = "YOUR_TOKEN", email = "YOUR_EMAIL")

1. Data template

years <- seq(1990, 2020)
df    <- data.frame(year               = years, 
                   `European Union`    = NA,
                   `Middle East`       = NA,
                   `Latin America`     = NA,
                   `Asia`              = NA,
                   `All countries` = NA, check.names = F)

2. Analyze

st  <- analyze(df)

2a. adjust

st  <- adjust(st, 
              column = c(2, 3, 4, 5, 6), 
              items = list("class" = "geography", "feature" = "generic", "cleaner" = NA, "format" = NA, "provider" = "REJUSTIFY", "table" = "BRUEGEL-GINI"))

3. Fill data

rdf <- fill(df, st, accu = 0.5)
vis(rdf)

3a. Adjust default values

def <- adjust(rdf$default, column = c(2, 3, 4, 5, 6), items = list("Method" = "LP")) #depending on the method

3b. Refill data

rdf <- fill(df, st, default = def)