corruption: Corruption Perceptions Index (CPI) and Human Development...

Description Usage Format References Examples

Description

Corruption Perceptions Index (CPI) and Human Development Index (HDI) for 176 countries, from 2012 to 2015.

Usage

1

Format

An object of class tbl_df (inherits from tbl, data.frame) with 704 rows and 6 columns.

References

Corruption Perceptions Index: https://www.transparency.org/news/feature/corruption_perceptions_index_2016#table

Human Development Index: http://hdr.undp.org/en/data#

Original figure idea: https://www.economist.com/blogs/dailychart/2011/12/corruption-and-development

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
library(tidyverse)
library(cowplot)

corruption %>%
  filter(year == 2015) %>%
  na.omit() %>%
  ggplot(aes(cpi, hdi)) + geom_point(aes(color = region)) +
  geom_smooth(method = 'lm', formula = y~log(x), se = FALSE) +
  scale_color_brewer(name = NULL, type = "qual") +
  theme_minimal_hgrid() +
  theme(legend.position = "top")

wilkelab/practicalgg documentation built on Feb. 6, 2021, 6:52 a.m.