From 4e6662381a559ce9a08a47c1e2c4898d7f18e042 Mon Sep 17 00:00:00 2001 From: Sid Kapur Date: Sat, 23 Sep 2023 20:31:06 -0400 Subject: [PATCH] Change spelling "Jersey, NJ" -> "Jersey City, NJ" --- python/housing_data/build_places.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/python/housing_data/build_places.py b/python/housing_data/build_places.py index 6f4509d..57296e4 100644 --- a/python/housing_data/build_places.py +++ b/python/housing_data/build_places.py @@ -286,6 +286,9 @@ def get_name_spelling(places_df: pd.DataFrame) -> pd.Series: ].str.contains("Parish") name = is_unincorporated.map({True: "Unincorporated ", False: ""}) + name + # Fix Jersey City, NJ + name[(name == "Jersey") & (places_df["state_code"] == 34)] = "Jersey City" + return name