added missing region

This commit is contained in:
Khalim Conn-Kowlessar 2025-08-26 12:33:26 +01:00
parent f0da057a69
commit 9d592838f5
2 changed files with 2 additions and 4 deletions

View file

@ -75,9 +75,6 @@ class EpcClean:
]
]
# Average
filtered_data.groupby("lighting-description")["low-energy-lighting"].mean().reset_index()
# Convert low-energy-lighting to float
for row in filtered_data:
row["low-energy-lighting"] = float(row["low-energy-lighting"])
@ -93,7 +90,7 @@ class EpcClean:
# Scale to between 0 and 1
averages = [{
"lighting-description": correct_spelling(description.lower()) / 100,
"lighting-description": correct_spelling(description.lower()),
"low-energy-lighting": total / counts[description] / 100
} for description, total in sums.items()]

View file

@ -164,6 +164,7 @@ county_to_region_map = {
'Wakefield': 'Yorkshire and the Humber', 'West Yorkshire': 'Yorkshire and the Humber',
'York': 'Yorkshire and the Humber',
'Westmorland': 'North West England',
'Westmorland and Furness': 'North West England',
# Additional mappings requried, based on what we find in the EPC database
'Greater London Authority': 'Inner London',