mirror of
https://github.com/DOI-DO/j40-cejst-2.git
synced 2025-07-27 22:41:17 -07:00
Alternative definition of DACs for comparison (#1068)
* Alternative energy-related definition of DACs
This commit is contained in:
parent
e15bb52bad
commit
beb0eea5cc
6 changed files with 164 additions and 0 deletions
|
@ -276,6 +276,25 @@
|
|||
"mapping_inequality_df"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
"id": "605af1ff",
|
||||
"metadata": {},
|
||||
"outputs": [],
|
||||
"source": [
|
||||
"# Load alternative energy-related definition \n",
|
||||
"energy_definition_alternative_draft_path = (\n",
|
||||
" DATA_DIR / \"dataset\" / \"energy_definition_alternative_draft\" / \"usa.csv\"\n",
|
||||
")\n",
|
||||
"energy_definition_alternative_draft_df = pd.read_csv(\n",
|
||||
" energy_definition_alternative_draft_path,\n",
|
||||
" dtype={ExtractTransformLoad.GEOID_TRACT_FIELD_NAME: \"string\"},\n",
|
||||
")\n",
|
||||
"\n",
|
||||
"energy_definition_alternative_draft_df"
|
||||
]
|
||||
},
|
||||
{
|
||||
"cell_type": "code",
|
||||
"execution_count": null,
|
||||
|
@ -291,6 +310,7 @@
|
|||
" calenviroscreen_df,\n",
|
||||
" persistent_poverty_df,\n",
|
||||
" mapping_inequality_df,\n",
|
||||
" energy_definition_alternative_draft_df,\n",
|
||||
"]\n",
|
||||
"\n",
|
||||
"merged_df = functools.reduce(\n",
|
||||
|
@ -431,6 +451,11 @@
|
|||
" priority_communities_field=PERSISTENT_POVERTY_TRACT_LEVEL_FIELD,\n",
|
||||
" other_census_tract_fields_to_keep=[],\n",
|
||||
" ),\n",
|
||||
" Index(\n",
|
||||
" method_name=field_names.ENERGY_RELATED_COMMUNITIES_DEFINITION_ALTERNATIVE,\n",
|
||||
" priority_communities_field=field_names.ENERGY_RELATED_COMMUNITIES_DEFINITION_ALTERNATIVE,\n",
|
||||
" other_census_tract_fields_to_keep=[],\n",
|
||||
" ),\n",
|
||||
" ]\n",
|
||||
" # Insert indices for each of the HOLC factors.\n",
|
||||
" # Note: since these involve no renaming, we write them using list comprehension.\n",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue