worked through ha13 matching - need to do facts and figures

This commit is contained in:
Khalim Conn-Kowlessar 2024-03-08 19:32:42 +00:00
parent b2b8fd8f84
commit 21117f3e58

View file

@ -174,6 +174,7 @@ class DataLoader:
"HA2": 0,
"HA6": 117,
"HA12": 6,
"HA13": 119,
"HA14": 3,
"HA15": 3,
"HA16": 7,
@ -1621,6 +1622,30 @@ class DataLoader:
"ALLANDALE ROAD", "ALLANDALE"
)
survey_list["Street / Block Name"] = survey_list["Street / Block Name"].str.replace(
"NEWFIELDS LANE", "NEWFIELD LANE"
)
survey_list["Street / Block Name"] = survey_list["Street / Block Name"].str.replace(
"BROADFIELDS ROAD", "BROADFIELD ROAD"
)
survey_list["Post Code"] = survey_list["Post Code"].str.replace(
"HP2 5SF+", "HP2 5SF"
)
survey_list["Street / Block Name"] = survey_list["Street / Block Name"].str.replace(
"PESCOTT HILL", "PESCOT HILL"
)
# This is a duplicate record
survey_list = survey_list[
~((survey_list["NO."] == 33) &
(survey_list["Street / Block Name"] == "Turners Hill") &
(survey_list["Post Code"] == "HP2 4LH") &
(survey_list["INSTALLED OR CANCELLED"] == "NO UPDATE - CHECKED 18.12.23"))
]
return survey_list
@staticmethod
@ -1652,6 +1677,9 @@ class DataLoader:
postcode.lower() not in asset_list["matching_postcode"].values
]
if ha_name == "HA13":
missed_postcodes = ["hp17 8le"]
matching_lookup = []
for _, row in tqdm(survey_list.iterrows(), total=len(survey_list)):