A stub post for collecting together:
- code libraries that wrap APIs and datasets related to UK Parliament data;
- downloadable datasets (raw and annotated);
- API endpoints;
- etc.
If you know of any others, please let me know via the comments…
APIs
Official Parliament APIs
- UK Parliament data API: data from UK Parliament; the catalogue is most easily explored via http://explore.data.parliament.uk/.
- UK Parliament Members Data Platform (MNIS)
Secondary Source APIs
Python
mnis
: a small Python library that makes it easy to download data on UK Members of Parliament fromhttp://data.parliament.uk/membersdataplatform
(about)- They Work For You API: no longer maintained?
R
hansard
: R package to automatically fetch data from the UK Parliament API; but not Hansard!twfy
: R wrapper for TheyWorkForYou’s API (about)twfyR
: another R wrapper for TheyWorkForYou’s API
Data Sourcing Applications
- Popbuilder: combined population estimates by selected LSOA (about, code)
- Constituency Boundaries: tool for exploring current and proposed constituency boundaries and downloading name, code, and Parliamentary electorate data (about)
Scrapers
- Parlparse: scripts from They Work For You for scraping Parlimanet website
- Members interests scraper (
node.js?
: (no README/howto) - (old/archived APPG scraper (
py
))
Datasets
- Hansard Speeches and Sentiment: a public dataset of speeches in Hansard, with information on the speaking MP, their party, gender and age at the time of the speech. (Large files (~3GB) – example of how to query datafile using Apache Drill.)
Data Handling Utilities
R
code for internal DfT tool for Transport Appraisal and Strategic modelling (TASM) use: convert outputs from the National Trip End Model (NTEM) for use in the National Transport Model (NTM);