mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-06-08 11:17:27 +00:00
updating facts and figures to treat archetype dependent properties separately
This commit is contained in:
parent
21117f3e58
commit
f03485d4f4
1 changed files with 12 additions and 6 deletions
|
|
@ -2172,13 +2172,12 @@ class DataLoader:
|
|||
eco_eligibility_map = {
|
||||
"not eligble": "not eligible",
|
||||
"eco 4(subject to ciga)": "eco4 (subject to ciga)",
|
||||
"eco4 (subject to ciga/archetype check": "eco4 (subject to ciga)",
|
||||
"eco4 (subject to archetype check)": "eco4 (subject to ciga)",
|
||||
"eco4 (subject to ciga/archetype)": "eco4 (subject to ciga)",
|
||||
"eco4 (subject to ciga/archetype check": "eco4 (subject to ciga) (subject to archetype)",
|
||||
"eco4 (subject to archetype check)": "eco4 (subject to archetype)",
|
||||
"eco4 (subject to ciga/archetype)": "eco4 (subject to ciga) (subject to archetype)",
|
||||
"eco4 (subject to ciga)": "eco4 (subject to ciga)",
|
||||
"eco4(subject to ciga)": "eco4 (subject to ciga)",
|
||||
"eco4 subject to ciga": "eco4 (subject to ciga)",
|
||||
"eco4 (subject to archetype)": "eco4 (subject to ciga)",
|
||||
}
|
||||
|
||||
ha_facts_and_figures = []
|
||||
|
|
@ -2330,7 +2329,7 @@ class DataLoader:
|
|||
asset_list = asset_list.merge(survey_list_to_merge, how='left', on="asset_list_row_id")
|
||||
# Update the cases where properties have sold, but are missing a CIGA check
|
||||
asset_list["ECO Eligibility"] = np.where(
|
||||
(asset_list["ECO Eligibility"] == "eco4 (subject to ciga)") & (
|
||||
(asset_list["ECO Eligibility"].str.contains("(subject to ciga)")) & (
|
||||
asset_list["has_a_survey_record"] == True
|
||||
),
|
||||
"eco4 - passed ciga",
|
||||
|
|
@ -2349,7 +2348,14 @@ class DataLoader:
|
|||
# Update the cases where a property was marked as eligible for ECO4, but sold for GBIS
|
||||
asset_list["ECO Eligibility"] = np.where(
|
||||
(asset_list["ECO Eligibility"].isin(
|
||||
["eco4", "eco4 (subject to ciga)", "eco4 - passed ciga", "failed ciga"]
|
||||
[
|
||||
"eco4",
|
||||
"eco4 (subject to ciga)",
|
||||
"eco4 - passed ciga",
|
||||
"failed ciga",
|
||||
"eco4 (subject to archetype)",
|
||||
"eco4 (subject to ciga) (subject to archetype)"
|
||||
]
|
||||
)) & (
|
||||
asset_list["installation_status"].isin(
|
||||
["GBIS - installed", "GBIS - cancelled", "GBIS - in progress"]
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue