{
  "schemaVersion": 1,
  "slug": "taiwan-k-shaped-card-spending",
  "title": "Taiwan K-Shaped Card Spending",
  "createdAt": "2026-06-18T11:51:59.199335+00:00",
  "sources": {
    "nccc": {
      "urlTemplate": "https://bas.nccc.com.tw/nccc-nop/OpenAPI/C03/incomegroupsconsumption/{region_code}/{industry_code}",
      "regionCode": "TWN",
      "industryCodes": {
        "ALL": "全部產業",
        "FD": "食",
        "CT": "衣",
        "LG": "住",
        "TR": "行",
        "EE": "文教康樂",
        "DP": "百貨",
        "OT": "其他"
      },
      "note": "NCCC aggregate credit-card signing amount and transaction count by fixed personal-income bins; main groups are bin-split personal-income proxies."
    },
    "dgbasIncomeCpi": {
      "url": "https://nstatdb.dgbas.gov.tw/dgbasAll/webMain.aspx?sdmx/A030104015",
      "functionCode": "A030104015"
    },
    "dgbasRetailBenchmark": {
      "url": "https://nstatdb.dgbas.gov.tw/dgbasAll/webMain.aspx?sdmx/A050107020",
      "functionCode": "A050107020",
      "series": [
        "零售業",
        "餐飲業"
      ]
    },
    "widTaiwanWealth": {
      "url": "https://wid.world/bulk_download/WID_fulldataset_TW.zip",
      "variable": "shwealj992",
      "note": "WID appendix only; not an official Taiwan Open API."
    }
  },
  "incomeGroups": {
    "Lower": {
      "label": "Low personal-income proxy",
      "percentile_proxy": "bottom 20%",
      "income_range": "未滿38.1萬",
      "lower_ntd": 0.0,
      "upper_ntd": 381000.0
    },
    "Middle": {
      "label": "Middle personal-income proxy",
      "percentile_proxy": "P20-P80",
      "income_range": "38.1萬到未滿95.9萬",
      "lower_ntd": 381000.0,
      "upper_ntd": 959000.0
    },
    "Higher": {
      "label": "High personal-income proxy",
      "percentile_proxy": "top 20%",
      "income_range": "95.9萬以上",
      "lower_ntd": 959000.0,
      "upper_ntd": null
    }
  },
  "allocationTable": [
    {
      "income_band": "未達50萬",
      "income_band_lower_ntd": 0.0,
      "income_band_upper_ntd": 500000.0,
      "income_group": "Lower",
      "income_group_label": "Low personal-income proxy",
      "personal_income_proxy": "bottom 20%",
      "proxy_income_range": "未滿38.1萬",
      "allocation_weight": 0.762,
      "cpi_income_level": "最低20%所得家庭"
    },
    {
      "income_band": "未達50萬",
      "income_band_lower_ntd": 0.0,
      "income_band_upper_ntd": 500000.0,
      "income_group": "Middle",
      "income_group_label": "Middle personal-income proxy",
      "personal_income_proxy": "P20-P80",
      "proxy_income_range": "38.1萬到未滿95.9萬",
      "allocation_weight": 0.238,
      "cpi_income_level": "中間60%所得家庭"
    },
    {
      "income_band": "50(含)-75萬",
      "income_band_lower_ntd": 500000.0,
      "income_band_upper_ntd": 750000.0,
      "income_group": "Middle",
      "income_group_label": "Middle personal-income proxy",
      "personal_income_proxy": "P20-P80",
      "proxy_income_range": "38.1萬到未滿95.9萬",
      "allocation_weight": 1.0,
      "cpi_income_level": "中間60%所得家庭"
    },
    {
      "income_band": "75(含)-100萬",
      "income_band_lower_ntd": 750000.0,
      "income_band_upper_ntd": 1000000.0,
      "income_group": "Middle",
      "income_group_label": "Middle personal-income proxy",
      "personal_income_proxy": "P20-P80",
      "proxy_income_range": "38.1萬到未滿95.9萬",
      "allocation_weight": 0.836,
      "cpi_income_level": "中間60%所得家庭"
    },
    {
      "income_band": "75(含)-100萬",
      "income_band_lower_ntd": 750000.0,
      "income_band_upper_ntd": 1000000.0,
      "income_group": "Higher",
      "income_group_label": "High personal-income proxy",
      "personal_income_proxy": "top 20%",
      "proxy_income_range": "95.9萬以上",
      "allocation_weight": 0.164,
      "cpi_income_level": "最高20%所得家庭"
    },
    {
      "income_band": "100(含)-125萬",
      "income_band_lower_ntd": 1000000.0,
      "income_band_upper_ntd": 1250000.0,
      "income_group": "Higher",
      "income_group_label": "High personal-income proxy",
      "personal_income_proxy": "top 20%",
      "proxy_income_range": "95.9萬以上",
      "allocation_weight": 1.0,
      "cpi_income_level": "最高20%所得家庭"
    },
    {
      "income_band": "125(含)-150萬",
      "income_band_lower_ntd": 1250000.0,
      "income_band_upper_ntd": 1500000.0,
      "income_group": "Higher",
      "income_group_label": "High personal-income proxy",
      "personal_income_proxy": "top 20%",
      "proxy_income_range": "95.9萬以上",
      "allocation_weight": 1.0,
      "cpi_income_level": "最高20%所得家庭"
    },
    {
      "income_band": "150(含)-175萬",
      "income_band_lower_ntd": 1500000.0,
      "income_band_upper_ntd": 1750000.0,
      "income_group": "Higher",
      "income_group_label": "High personal-income proxy",
      "personal_income_proxy": "top 20%",
      "proxy_income_range": "95.9萬以上",
      "allocation_weight": 1.0,
      "cpi_income_level": "最高20%所得家庭"
    },
    {
      "income_band": "175(含)-200萬",
      "income_band_lower_ntd": 1750000.0,
      "income_band_upper_ntd": 2000000.0,
      "income_group": "Higher",
      "income_group_label": "High personal-income proxy",
      "personal_income_proxy": "top 20%",
      "proxy_income_range": "95.9萬以上",
      "allocation_weight": 1.0,
      "cpi_income_level": "最高20%所得家庭"
    },
    {
      "income_band": "200(含)萬以上",
      "income_band_lower_ntd": 2000000.0,
      "income_band_upper_ntd": null,
      "income_group": "Higher",
      "income_group_label": "High personal-income proxy",
      "personal_income_proxy": "top 20%",
      "proxy_income_range": "95.9萬以上",
      "allocation_weight": 1.0,
      "cpi_income_level": "最高20%所得家庭"
    }
  ],
  "cpiBridge": {
    "Lower": "最低20%所得家庭",
    "Middle": "中間60%所得家庭",
    "Higher": "最高20%所得家庭"
  },
  "baseMonths": [
    "2018-01",
    "2020-01",
    "2023-01"
  ],
  "mainBaseMonth": "2023-01",
  "metrics": {
    "latest_month": "2026-03",
    "benchmark_yoy_corr": 0.3263731568155817,
    "latest_real_index_lower": 107.67662889332999,
    "latest_real_index_middle": 111.31947259247002,
    "latest_real_index_higher": 131.37191607861817,
    "latest_k_gap_index_points": 23.69528718528818,
    "latest_k_gap_log_points": 19.889979603902155,
    "post_k_gap_shift_index_points": 13.90646319356825,
    "nccc_start_month": "2014-01",
    "nccc_latest_month": "2026-03",
    "analysis_start_month": "2018-01",
    "analysis_latest_month": "2026-03"
  },
  "qaGates": [
    {
      "name": "required sources fetched and cached",
      "passed": true,
      "detail": "11 raw files cached under /Users/qin/side_projects_workspace/pyivest/.cache/taiwan-k-shaped-card-spending/raw"
    },
    {
      "name": "required NCCC columns present",
      "passed": true,
      "detail": "card_amount_ntd, income_band, industry_name, month, region_name, tx_count"
    },
    {
      "name": "8 NCCC income bins exactly matched",
      "passed": true,
      "detail": "未達50萬, 50(含)-75萬, 75(含)-100萬, 100(含)-125萬, 125(含)-150萬, 150(含)-175萬, 175(含)-200萬, 200(含)萬以上"
    },
    {
      "name": "NCCC key uniqueness",
      "passed": true,
      "detail": "month + industry_code + income_band is unique in ALL endpoint"
    },
    {
      "name": "non-negative amounts and transactions",
      "passed": true,
      "detail": "card_amount_ntd >= 0 and tx_count >= 0"
    },
    {
      "name": "personal-income proxy allocation weights complete",
      "passed": true,
      "detail": "NCCC bins are split at 381k and 959k annual personal-income thresholds"
    },
    {
      "name": "CPI bridge complete",
      "passed": true,
      "detail": "all personal-income proxy groups have a household income-level CPI proxy"
    },
    {
      "name": "base months present",
      "passed": true,
      "detail": "2018-01, 2020-01, 2023-01"
    },
    {
      "name": "DGBAS benchmark parses retail and food-service",
      "passed": true,
      "detail": "批發、零售及餐飲業合計, 批發業, 零售業, 餐飲業"
    },
    {
      "name": "YoY overlap sufficient for benchmark correlation",
      "passed": true,
      "detail": "87 overlapping YoY months"
    },
    {
      "name": "WID p20p80 constructed",
      "passed": true,
      "detail": "p20p80 = p0p80 - p0p20 for shwealj992 wealth share"
    },
    {
      "name": "all public data tables and figures generated",
      "passed": true,
      "detail": "11 data/figure artifacts"
    },
    {
      "name": "no raw cache files under public artifacts",
      "passed": true,
      "detail": "raw downloads are cached under .cache and excluded from public data"
    }
  ],
  "caveats": [
    "NCCC data are aggregate credit-card signing amounts and transaction counts, not all household consumption.",
    "NCCC fixed personal-income bins are split into percentile-proxy groups using within-bin interval weights.",
    "DGBAS income-level CPI is household-based; it is used because no matching personal-income CPI is available.",
    "WID wealth data are annual external estimates and only provide distributional context."
  ]
}