Data were munged here
In [33]:
import pandas as pd
import numpy as np
from IPython.core.display import display, HTML
display(HTML("<style>.container { width:100% !important; }</style>"))
In [34]:
df = pd.read_csv('../../data/processed/complaints-3-29-scrape.csv')
In [35]:
id_name = df[['facility_id','online_fac_name']][df['online_fac_name'].notnull()].drop_duplicates().rename(columns={'online_fac_name':'online_name'})
In [36]:
id_name.head()
Out[36]:
In [37]:
names_per_id = id_name.groupby('facility_id').count().reset_index()
In [38]:
names_per_id.head()
Out[38]:
In [39]:
names_per_id[names_per_id['online_name']>1].count()[0]
Out[39]:
Checking if multiple facilities have the same name