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
safegraph_df |
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
csv_gist_data = requests.get(CSV_URL).content | |
safegraph_df = pd.read_csv(io.StringIO(csv_gist_data.decode('utf-8')), index_col='ID') |
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
CSV_URL="https://gist.githubusercontent.com/Rubix982/ff3af3545a2f5b49a75aa7e76d1a4f72/raw/1f23dba6623122dafb31fa66d3c174ad5c5118d4/SafeGraphDataCleaned.csv" |
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 pandas as pd # for dataframes, converting str to a df | |
import io # preparing a string stream | |
import requests # fetching data from the GitHub Gist |
We can make this file beautiful and searchable if this error is corrected: It looks like row 7 should actually have 14 columns, instead of 4. in line 6.
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
ID,Location,Categories,Sub Categories,NAICS Code,Lat,Long,Street Address,City,Region,Postal Code,Country Code,Closed Since,Geometry Type | |
0,Allpoint ATM,Depository Credit Intermediation,Commercial Banking,522110,41.905919,-87.940391,110 W North Ave,Elmhurst,IL,60126,US,,POINT | |
1,Long Beach Transit DOWNEY & 68TH NE,Urban Transit Systems,Bus and Other Motor Vehicle Transit Systems,485113,33.87941,-118.15126,Downey & 68th NE,Bellflower,CA,90706,US,2019-07,POINT | |
2,TD Bank ATM,Depository Credit Intermediation,Commercial Banking,522110,44.25938,-76.584501,Esso,Kingston,ON,K7P 0K3,CA,2021-05,POINT | |
3,CO-OP Network ATM,Depository Credit Intermediation,Commercial Banking,522110,31.678713,-98.963365,3801 4th St,Brownwood,TX,76801,US,,POINT | |
4,Niagara Frontier Transportation Authority Centre Ave & 22nd St,Urban Transit Systems,Bus and Other Motor Vehicle Transit Systems,485113,43.113115,-79.036102,Centre Ave & 22nd St,Niagara Falls,NY,14305,US,2019-07,POINT | |
5,Burlington Transit CAVENDISH AT DEVLIN,Urban Transit Systems,Bus |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.