mirror of
https://github.com/DOI-DO/j40-cejst-2.git
synced 2025-07-28 22:01:16 -07:00
parent
f6efdd4e14
commit
b0a728437c
6 changed files with 54 additions and 8 deletions
|
@ -170,7 +170,7 @@ TSDF_FIELD = "Proximity to hazardous waste sites"
|
|||
NPL_FIELD = "Proximity to NPL sites"
|
||||
AIR_TOXICS_CANCER_RISK_FIELD = "Air toxics cancer risk"
|
||||
RESPIRATORY_HAZARD_FIELD = "Respiratory hazard index"
|
||||
UST_FIELD = "Underground storage tanks"
|
||||
UST_FIELD = "Leaky underground storage tanks"
|
||||
|
||||
LOW_INCOME_THRESHOLD = "Exceeds FPL200 threshold"
|
||||
|
||||
|
@ -430,6 +430,8 @@ HAZARDOUS_WASTE_LOW_INCOME_FIELD = (
|
|||
|
||||
# Critical Clean Water and Waste Infrastructure
|
||||
WASTEWATER_DISCHARGE_LOW_INCOME_FIELD = f"Greater than or equal to the {PERCENTILE}th percentile for wastewater discharge and is low income?"
|
||||
UST_LOW_INCOME_FIELD = f"Greater than or equal to the {PERCENTILE}th percentile for leaky underground storage tanks and is low income?"
|
||||
|
||||
|
||||
# Health Burdens
|
||||
DIABETES_LOW_INCOME_FIELD = f"Greater than or equal to the {PERCENTILE}th percentile for diabetes and is low income?"
|
||||
|
@ -629,6 +631,8 @@ RMP_PCTILE_THRESHOLD = (
|
|||
NPL_PCTILE_THRESHOLD = f"Greater than or equal to the {PERCENTILE}th percentile for NPL (superfund sites) proximity"
|
||||
TSDF_PCTILE_THRESHOLD = f"Greater than or equal to the {PERCENTILE}th percentile for proximity to hazardous waste sites"
|
||||
WASTEWATER_PCTILE_THRESHOLD = f"Greater than or equal to the {PERCENTILE}th percentile for wastewater discharge"
|
||||
UST_PCTILE_THRESHOLD = f"Greater than or equal to the {PERCENTILE}th percentile for leaky underwater storage tanks"
|
||||
|
||||
DIABETES_PCTILE_THRESHOLD = (
|
||||
f"Greater than or equal to the {PERCENTILE}th percentile for diabetes"
|
||||
)
|
||||
|
|
|
@ -442,23 +442,42 @@ class ScoreNarwhal(Score):
|
|||
]
|
||||
>= self.ENVIRONMENTAL_BURDEN_THRESHOLD
|
||||
)
|
||||
|
||||
# Straight copy here in case we add additional water fields.
|
||||
self.df[field_names.WATER_THRESHOLD_EXCEEDED] = self.df[
|
||||
field_names.WASTEWATER_PCTILE_THRESHOLD
|
||||
].copy()
|
||||
self.df[field_names.UST_PCTILE_THRESHOLD] = (
|
||||
self.df[field_names.UST_FIELD + field_names.PERCENTILE_FIELD_SUFFIX]
|
||||
>= self.ENVIRONMENTAL_BURDEN_THRESHOLD
|
||||
)
|
||||
|
||||
self.df[field_names.WASTEWATER_DISCHARGE_LOW_INCOME_FIELD] = (
|
||||
self.df[field_names.WASTEWATER_PCTILE_THRESHOLD]
|
||||
& self.df[field_names.FPL_200_SERIES_IMPUTED_AND_ADJUSTED]
|
||||
)
|
||||
|
||||
self.df[field_names.UST_LOW_INCOME_FIELD] = (
|
||||
self.df[field_names.UST_PCTILE_THRESHOLD]
|
||||
& self.df[field_names.FPL_200_SERIES_IMPUTED_AND_ADJUSTED]
|
||||
)
|
||||
|
||||
self.df[field_names.WATER_THRESHOLD_EXCEEDED] = self.df[
|
||||
[
|
||||
field_names.WASTEWATER_PCTILE_THRESHOLD,
|
||||
field_names.UST_PCTILE_THRESHOLD,
|
||||
]
|
||||
].max(axis=1)
|
||||
|
||||
self._increment_total_eligibility_exceeded(
|
||||
[field_names.WASTEWATER_DISCHARGE_LOW_INCOME_FIELD],
|
||||
[
|
||||
field_names.WASTEWATER_DISCHARGE_LOW_INCOME_FIELD,
|
||||
field_names.UST_LOW_INCOME_FIELD,
|
||||
],
|
||||
skip_fips=constants.DROP_FIPS_FROM_NON_WTD_THRESHOLDS,
|
||||
)
|
||||
|
||||
return self.df[field_names.WASTEWATER_DISCHARGE_LOW_INCOME_FIELD]
|
||||
return self.df[
|
||||
[
|
||||
field_names.WASTEWATER_DISCHARGE_LOW_INCOME_FIELD,
|
||||
field_names.UST_LOW_INCOME_FIELD,
|
||||
]
|
||||
].any(axis=1)
|
||||
|
||||
def _health_factor(self) -> bool:
|
||||
# In Xth percentile or above for diabetes (Source: CDC Places)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue