This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import json | |
import csv | |
import requests | |
headers = {'X-API-Key': 'DzoRodfNtDdLcIOVzLWcaApiRvDTzXR48CPPyc93'} | |
offset=0 | |
for item in range(0, 1520): | |
url='https://api.propublica.org/congress/v2/members/F000444/votes.json?offset={0}'.format(offset) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@cache_control(public=True, max_age=300) | |
def recruiting_year(request, yslug): | |
year = get_object_or_404(RecruitClass, year_slug=yslug) | |
recruiting_year = 1 | |
years = RecruitClass.objects.all().order_by('year') | |
player = Recruit.objects.filter(college_class__year_slug=yslug).filter(Q(signing_day_pick_school__school__short_name="Florida")|Q(verbal_commit_pick_school__school__short_name="Florida")).filter(Q(committed_status__status="Signed")|Q(committed_status__status="Verbal")).order_by('last_name') | |
return render_to_response('year_detail.html', { | |
'player': player, | |
'year': year, | |
'years': years, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
''' | |
This script was used to convert the 2009 Q3 House Disbursement PDF into detail and summary CSV files. | |
Source PDF: http://disbursements.house.gov/ | |
Resulting Data: http://www.sunlightfoundation.com/projects/2009/expenditures/ | |
It was originally authored by Luke Rosiak with improvements by James Turk for Sunlight Labs and is released into the public domain. |