mirror of
https://github.com/DOI-DO/j40-cejst-2.git
synced 2025-07-28 13:51:16 -07:00
adding median income field and running black
This commit is contained in:
parent
6c986adfe4
commit
4ae7eff4c4
6 changed files with 33 additions and 10 deletions
|
@ -34,7 +34,8 @@ class HudHousingETL(ExtractTransformLoad):
|
|||
def extract(self) -> None:
|
||||
logger.info("Extracting HUD Housing Data")
|
||||
super().extract(
|
||||
self.HOUSING_FTP_URL, self.HOUSING_ZIP_FILE_DIR,
|
||||
self.HOUSING_FTP_URL,
|
||||
self.HOUSING_ZIP_FILE_DIR,
|
||||
)
|
||||
|
||||
def transform(self) -> None:
|
||||
|
@ -48,7 +49,10 @@ class HudHousingETL(ExtractTransformLoad):
|
|||
/ "140"
|
||||
/ "Table8.csv"
|
||||
)
|
||||
self.df = pd.read_csv(filepath_or_buffer=tmp_csv_file_path, encoding="latin-1",)
|
||||
self.df = pd.read_csv(
|
||||
filepath_or_buffer=tmp_csv_file_path,
|
||||
encoding="latin-1",
|
||||
)
|
||||
|
||||
# Rename and reformat block group ID
|
||||
self.df.rename(columns={"geoid": self.GEOID_TRACT_FIELD_NAME}, inplace=True)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue