{ "cells": [ { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [], "source": [ "import pandas as pd\n", "import os\n", "\n", "from helpers import (\n", " get_data_path_for_config,\n", " get_combined_df,\n", " save_final_df_as_jsonl,\n", " handle_slug_column_mappings,\n", " set_home_type,\n", ")" ] }, { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [], "source": [ "CONFIG_NAME = \"for_sale_listings\"" ] }, { "cell_type": "code", "execution_count": 3, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "processing Metro_new_pending_uc_sfrcondo_sm_month.csv\n", "processing Metro_invt_fs_uc_sfrcondo_week.csv\n", "processing Metro_mlp_uc_sfrcondo_week.csv\n", "processing Metro_invt_fs_uc_sfr_month.csv\n", "processing Metro_mlp_uc_sfr_sm_month.csv\n", "processing Metro_new_pending_uc_sfrcondo_month.csv\n", "processing Metro_mlp_uc_sfrcondo_sm_week.csv\n", "processing Metro_invt_fs_uc_sfrcondo_month.csv\n", "processing Metro_mlp_uc_sfr_sm_week.csv\n", "processing Metro_mlp_uc_sfrcondo_month.csv\n", "processing Metro_new_pending_uc_sfrcondo_sm_week.csv\n", "processing Metro_invt_fs_uc_sfr_sm_week.csv\n", "processing Metro_invt_fs_uc_sfr_sm_month.csv\n", "processing Metro_mlp_uc_sfr_month.csv\n", "processing Metro_new_listings_uc_sfrcondo_week.csv\n", "processing Metro_mlp_uc_sfrcondo_sm_month.csv\n", "processing Metro_invt_fs_uc_sfrcondo_sm_week.csv\n", "processing Metro_new_listings_uc_sfrcondo_sm_week.csv\n", "processing Metro_new_listings_uc_sfrcondo_month.csv\n", "processing Metro_new_pending_uc_sfrcondo_week.csv\n", "processing Metro_invt_fs_uc_sfr_week.csv\n", "processing Metro_new_listings_uc_sfrcondo_sm_month.csv\n", "processing Metro_mlp_uc_sfr_week.csv\n", "processing Metro_invt_fs_uc_sfrcondo_sm_month.csv\n" ] }, { "data": { "text/html": [ "
\n", " | RegionID | \n", "SizeRank | \n", "RegionName | \n", "RegionType | \n", "StateName | \n", "Home Type | \n", "Date | \n", "Median Listing Price | \n", "Median Listing Price (Smoothed) | \n", "New Pending (Smoothed) | \n", "New Listings | \n", "New Listings (Smoothed) | \n", "New Pending | \n", "
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | \n", "102001 | \n", "0 | \n", "United States | \n", "country | \n", "NaN | \n", "SFR | \n", "2018-01-13 | \n", "259000.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
1 | \n", "102001 | \n", "0 | \n", "United States | \n", "country | \n", "NaN | \n", "SFR | \n", "2018-01-20 | \n", "259900.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
2 | \n", "102001 | \n", "0 | \n", "United States | \n", "country | \n", "NaN | \n", "SFR | \n", "2018-01-27 | \n", "259900.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
3 | \n", "102001 | \n", "0 | \n", "United States | \n", "country | \n", "NaN | \n", "SFR | \n", "2018-02-03 | \n", "260000.0 | \n", "259700.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
4 | \n", "102001 | \n", "0 | \n", "United States | \n", "country | \n", "NaN | \n", "SFR | \n", "2018-02-10 | \n", "264900.0 | \n", "261175.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "
578648 | \n", "845172 | \n", "769 | \n", "Winfield, KS | \n", "msa | \n", "KS | \n", "all homes | \n", "2023-12-09 | \n", "134950.0 | \n", "138913.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
578649 | \n", "845172 | \n", "769 | \n", "Winfield, KS | \n", "msa | \n", "KS | \n", "all homes | \n", "2023-12-16 | \n", "120000.0 | \n", "133938.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
578650 | \n", "845172 | \n", "769 | \n", "Winfield, KS | \n", "msa | \n", "KS | \n", "all homes | \n", "2023-12-23 | \n", "111000.0 | \n", "126463.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
578651 | \n", "845172 | \n", "769 | \n", "Winfield, KS | \n", "msa | \n", "KS | \n", "all homes | \n", "2023-12-30 | \n", "126950.0 | \n", "123225.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
578652 | \n", "845172 | \n", "769 | \n", "Winfield, KS | \n", "msa | \n", "KS | \n", "all homes | \n", "2024-01-06 | \n", "128000.0 | \n", "121488.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
578653 rows × 13 columns
\n", "\n", " | Region ID | \n", "Size Rank | \n", "Region | \n", "Region Type | \n", "State | \n", "Home Type | \n", "Date | \n", "Median Listing Price | \n", "Median Listing Price (Smoothed) | \n", "New Pending (Smoothed) | \n", "New Listings | \n", "New Listings (Smoothed) | \n", "New Pending | \n", "
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
0 | \n", "102001 | \n", "0 | \n", "United States | \n", "country | \n", "NaN | \n", "SFR | \n", "2018-01-13 | \n", "259000.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
1 | \n", "102001 | \n", "0 | \n", "United States | \n", "country | \n", "NaN | \n", "SFR | \n", "2018-01-20 | \n", "259900.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
2 | \n", "102001 | \n", "0 | \n", "United States | \n", "country | \n", "NaN | \n", "SFR | \n", "2018-01-27 | \n", "259900.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
3 | \n", "102001 | \n", "0 | \n", "United States | \n", "country | \n", "NaN | \n", "SFR | \n", "2018-02-03 | \n", "260000.0 | \n", "259700.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
4 | \n", "102001 | \n", "0 | \n", "United States | \n", "country | \n", "NaN | \n", "SFR | \n", "2018-02-10 | \n", "264900.0 | \n", "261175.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "... | \n", "
578648 | \n", "845172 | \n", "769 | \n", "Winfield, KS | \n", "msa | \n", "KS | \n", "all homes | \n", "2023-12-09 | \n", "134950.0 | \n", "138913.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
578649 | \n", "845172 | \n", "769 | \n", "Winfield, KS | \n", "msa | \n", "KS | \n", "all homes | \n", "2023-12-16 | \n", "120000.0 | \n", "133938.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
578650 | \n", "845172 | \n", "769 | \n", "Winfield, KS | \n", "msa | \n", "KS | \n", "all homes | \n", "2023-12-23 | \n", "111000.0 | \n", "126463.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
578651 | \n", "845172 | \n", "769 | \n", "Winfield, KS | \n", "msa | \n", "KS | \n", "all homes | \n", "2023-12-30 | \n", "126950.0 | \n", "123225.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
578652 | \n", "845172 | \n", "769 | \n", "Winfield, KS | \n", "msa | \n", "KS | \n", "all homes | \n", "2024-01-06 | \n", "128000.0 | \n", "121488.0 | \n", "NaN | \n", "NaN | \n", "NaN | \n", "NaN | \n", "
578653 rows × 13 columns
\n", "