No description, website, or topics provided.
CSS PHP Python JavaScript
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
cache
data
js
scripts
src
.gitignore
LICENSE
README.md
column.php
requirements.txt

README.md

Congressional Social Networks

Quick setup

It's recommended to make a virtualenv, then run:

pip install -r requirements.txt

Data

All voting information comes from the incomparably awesome GovTrack.us. To prevent unnecessary hammering of GovTrack's API, all cached XML files and the associated JSON files are included in this repository.

If you insist on downloading them yourself, you can do so by running the fetch.py script:

Information on members comes from the congress-legislators project on the United States GitHub group. The YAML files from this project were converted to JSON for continuity and indexed by govtrack ID for easy lookup

fetch.py

Options: --session: Session of Congress for which you want to download votes. Default is 114. --rootdir: Root directory of project. Default is output of os.getcwd()

analyze.py

Measure the voting co-incidence for every combination of lawmakers.

Options: --session: Session of Congress for which you want to build a voting network. Default is 114. --chamber: Senate or House. Default is Senate. --rootdir: Root directory of project. Default is output of os.getcwd()

Visualization

This interactive uses d3's force-directed layout to form the network.