-
Notifications
You must be signed in to change notification settings - Fork 507
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Missing FEC IDs #932
Comments
Sorry, one additional omission there:
|
Thanks. I opened a PR to add this in #934. For posterity, I wrote this script to import it: import csv
import rtyaml
count = 0
for fn in ("current", "historical"):
with rtyaml.edit(f"../legislators-{fn}.yaml") as P:
PID = { }
for p in P:
PID[p["id"]["bioguide"]] = p
for rec in csv.DictReader(open("/home/user/Downloads/legislators_additional_fec_ids.csv")):
if rec["bioguide_id"] not in PID: continue
p = PID[rec["bioguide_id"]]
if "fec" not in p["id"]: p["id"]["fec"] = []
if rec["fec_id"] not in p["id"]["fec"]:
p["id"]["fec"].append(rec["fec_id"])
count += 1
print(count) |
Add FEC IDs to historical legislators submitted by @aaronrudkin in #932
But our tests caught some FEC IDs that now occur duplicated on legislators:
I would appreciate if you could resolve this (so that my effort to import this isn't wasted...). |
These are father/son pairs, good catch and my apologies for the wasted time -- I thought I had fixed all these before I let you know, but apparently had not. The correction:
Source for Lipinski: https://www.fec.gov/data/candidate/H2IL05019/ (Lipinski's son has bioguide ID L000563 and FEC ID H4IL03077) File with correction: |
Thank you! All fixed & merged. |
We're using your data downstream. Thanks! A few hundred legislators serving post-2000 have no FEC IDs listed, and for our purposes we have to join legislators to donation data, so this is a necessary crosswalk. Our downstream pull of your data is slightly out of date, so some of these might already be fixed, but I figured I'd contribute back the results of an automated attempt to populate these fields.
Attached is a CSV with the following format:
Column 1: bioguide_id
Column 2: first_name
Column 3: last_name
Column 4: thomas_id
Column 5: state
Column 6: fec_id
(You can probably just use 1 and 6)
legislators_additional_fec_ids.csv
Note that many entries have multiple FEC IDs. I manually screened for same-named father-son pairs to remove those. Hope this is useful.
The text was updated successfully, but these errors were encountered: