Skip to content

Latest commit

 

History

History
57 lines (36 loc) · 1.98 KB

README.md

File metadata and controls

57 lines (36 loc) · 1.98 KB

WiP-Tidy-Data-dt

Exercise for R-datatable-Tidy-Data Repo

Women in Parliament Hex Sticker

World Bank "Women in Parliament" Data

The raw data for "Proportion of seats held by women in national parliaments" ("single or lower parliamentary chambers only") by can be directly downloaded from:

As part of its "open data" mission the World Bank kindly offers "free and open access to global development data" licensed under the "Creative Commons Attribution 4.0 (CC-BY 4.0)".

Source Data

The data originates from the "Inter-Parliamentary Union" (IPU) which provides an "Archive of statistical data on the percentage of women in national parliaments" going back to 1997 on a monthly basis:

The World Bank data is for “single or lower parliamentary chambers only”, while the IPU also presents data for “Upper Houses or Senates”. Moreover, the IPU provides the actual numbers used to calculate the percentages (which the World Bank does not). The data has to be scraped from the IPU website (please check the robots.txt file first).

Importing the Raw Data into R

First download the latest CSV file from:

Below I will refer to this file as "WiP-Data.csv" but please use the actual file name that you save it as.

Using data.table

library(data.table)
wipdt <- fread("WiP-Data.csv",
               skip = 4, header = TRUE, check.names=TRUE)

Women in Parliament Bonus Image

Acknowledgements

The images were create by Marina Costa guided by Andreia Carlos and myself.

You can view Marina's great portfolio at: