Skip to content

Instantly share code, notes, and snippets.

View geramirez's full-sized avatar
:octocat:

Gabriel Ramírez geramirez

:octocat:
  • Amsterdam
  • 20:19 (UTC +02:00)
View GitHub Profile
@geramirez
geramirez / layer_with_usa_contacts.py
Created October 23, 2014 20:11
layer with us contacts
#Update Yaml files with usa_id and description
import yaml
import xlrd
import os
import json
from glob import glob
import re
from fuzzywuzzy import fuzz
@geramirez
geramirez / datamung.py
Last active August 29, 2015 14:08
GA-OauthFlow
request=service.data().ga().get(
ids='ga:' + "65544933",
start_date='2014-10-01',
end_date='2014-10-21',
metrics='ga:pageviews,ga:uniquePageviews',
dimensions='ga:region,ga:date',
filters="ga:country==United States").execute()
#import deps.
@geramirez
geramirez / email_only_no_form.txt
Created October 31, 2014 14:27
Quick Data Call #175
Nuclear Regulatory Commission
Federal Retirement Thrift Investment Board
Office of Special Counsel
Office of Science and Technology Policy
Consumer Product Safety Commission
Department of Justice
Bureau of Alcohol, Tobacco, Firearms, and Explosives
Drug Enforcement Administration
Federal Bureau of Investigation
Office of Community Oriented Policing Services
name,Web Form?,Comments,,
United States Secret Service,No email,,,
Nuclear Regulatory Commission,Email only,,,
Federal Retirement Thrift Investment Board,Email only,Was hard to find. FOIAREQUEST@tsp.gov,,
General Services Administration,https://foiaonline.regulations.gov/foia/action/public/home,,,
Export-Import Bank of the U.S.,http://www.exim.gov/about/library/foia/foia-request-form.cfm,,,
Department of State,http://foia.state.gov/Request/Submit.aspx,,,
Central Intelligence Agency,No email,,,
Office of Special Counsel,Email only,,,
Office of Science and Technology Policy,Email only,,,
@geramirez
geramirez / form_type.csv
Created November 4, 2014 21:47
validated forms
name Web Form? Comments
United States Secret Service No email
Nuclear Regulatory Commission Email only
Federal Retirement Thrift Investment Board Email only Was hard to find. FOIAREQUEST@tsp.gov
General Services Administration https://foiaonline.regulations.gov/foia/action/public/home
Export-Import Bank of the U.S. http://www.exim.gov/about/library/foia/foia-request-form.cfm
Department of State http://foia.state.gov/Request/Submit.aspx
Central Intelligence Agency No email
Office of Special Counsel Email only
Office of Science and Technology Policy Email only
@geramirez
geramirez / top_equals_dept.txt
Last active August 29, 2015 14:08
List of top levels = dept level
American Battle Monuments Commission
Administrative Conference of the United States
Armed Forces Retirement Home
Broadcasting Board of Governors
Council on Environmental Quality
Consumer Financial Protection Bureau
Commodity Futures Trading Commission
Central Intelligence Agency
Council of the Inspectors General on Integrity and Efficiency
Corporation for National and Community Service
@geramirez
geramirez / test
Created November 5, 2014 19:42
test
date close
1-May-12 582.13
30-Apr-12 583.98
27-Apr-12 603.00
26-Apr-12 607.70
25-Apr-12 610.00
24-Apr-12 560.28
23-Apr-12 571.70
20-Apr-12 572.98
19-Apr-12 587.44
@geramirez
geramirez / no_form.tsv
Last active August 29, 2015 14:09
no forms
Armed Forces Retirement Home department-of-veterans-affairs--board-of-veterans-appeals
Broadcasting Board of Governors department-of-veterans-affairs--board-of-veterans-appeals
Council on Environmental Quality department-of-veterans-affairs--board-of-veterans-appeals
Central Intelligence Agency department-of-veterans-affairs--board-of-veterans-appeals
United States Copyright Office department-of-veterans-affairs--board-of-veterans-appeals
Committee for Purchase from People Who Are Blind or Severely Disabled department-of-veterans-affairs--board-of-veterans-appeals
Chemical Safety and Hazard Investigation Board department-of-veterans-affairs--board-of-veterans-appeals
Department of Homeland Security department-of-veterans-affairs--board-of-veterans-appeals
U.S. Citizenship & Immigration Services department-of-veterans-affairs--board-of-veterans-appeals
U.S. Coast Guard department-of-veterans-affairs--board-of-veterans-appeals
@geramirez
geramirez / diff.csv
Last active August 29, 2015 14:10
differences
column name simple_average_days simple_median_days difference
5 AMTRAK (National Railroad Passenger Corporation) 4.17 1 3.17
12 Adjudicatory Boards (ARB, BRB, ECAB) 18.6 10 8.600000000000001
18 Administration for Children and Families 536 488 48.0
20 Administration for Community Living 13 14 -1.0
29 Administrative Conference of the United States 1.2 1 0.19999999999999996
38 Agency for Healthcare Research and Quality
42 Agricultural Marketing Service 16 15 1.0
48 Alcohol and Tobacco Tax and Trade Bureau 8.35 7 1.3499999999999996
52 American Battle Monuments Commission 72 11 61.0
@geramirez
geramirez / not_matched.csv
Created December 23, 2014 15:44
not matched
We can make this file beautiful and searchable if this error is corrected: It looks like row 2 should actually have 1 column, instead of 3. in line 1.
acquisition & material management_va
adjudicatory boards (arb, brb, ecab)_u.s. dol
administration on aging_hhs
administration_va
agency overall_hud
appeals_doi
appeals_va
assistant general counsel for administration_doc
authority member, administrative law judges & solicitor_flra
board of veterans' appeals_va