congressData
is an R package that contains CongressData, a dataset
assembled by Matt Grossmann, Caleb Lucas, Josh McCrain, and Ian
Ostrander. It compiles approximately 900 variables concerning all US
congressional districts and covers 1789-2021. Use the associated
congress package to subset the data
by states + years and export citations to common file formats
(e.g. bib). An associated web
application that enables easy
manipulation and exploration of the data is also available.
The CongressData codebook is available in this repo here.
A number of aggregations of the base member-year dataset (along with subsets) to member-sessions are also available. See the manual for documentation of every object in this package: congressData manual.
# Install from github
library(devtools)
install_github("ippsr/congressData")
Note that the congress
package imports the dataset automatically and
provides a number of helpful functions when working with it. You can
load the dataset with the data
function.
# Congress codebook
data("codebook")
# CongressData
data("congress")
Run get_congress_version
to see what version of the dataset is
currently in congressData
congressData::get_congress_version()
#> [1] "You are using version 1.4 of CongressData."
For questions about congressData please reach out to Ben Yoel (yoelbenj@msu.edu).
In addition to citing each variable’s source, we ask that you cite CongressData if use the dataset or this package. A recommended citation is below.
Grossmann, M., Lucas, C., McCrain, J, & Ostrander, I. (2022). CongressData. East Lansing, MI: Institute for Public Policy and Social Research (IPPSR)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.