Last active
December 12, 2015 05:18
-
-
Save rweald/4720846 to your computer and use it in GitHub Desktop.
Grab NPI numbers that could not be geocoded with high degree of confidence
This file contains hidden or 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 bash | |
# Requires CSVKit to be installed | |
# To install use pip install csvkit | |
cat geocoded_npi.csv | ruby -e 'STDIN.each { |l| fields = l.split(","); puts l if fields[3].to_f < 0.5 }' > lower-confidence-npis.csv | |
# Depending which address field you want to use you should change the column indexes | |
csvcut -c 1,29-33 full_nip_datadump.csv > npi-to-address.csv | |
csvjoin -c 1 npi-to-address.csv lower-confidence-npis.csv |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment