How To: Analyze Housing Stock Programmatically

These example notebooks and scripts demonstrate how users can access the ResStock datasets programmatically using the ResStock 2025 Release 1 dataset.Some dataset attributes, like column names or weighting factor applications, may change in the future. Check out the Data page for the most up to date information on ResStock datasets.

AWS Athena and SQL Queries

These scripts address three questions using SQL.

Python

Jupyter Notebook

Download the below Jupyter notebooks for the formatting to properly render. Previewing the notebooks online can present unreadable formatting.

  • Download Annual Baseline and Upgrade Data Example Jupyter notebook for pulling annual baseline and upgrade results from the Open Energy Data Initiative (OEDI) data lake. This example filters to a specific geography and housing type, and then plots a comparison.
  • Download Timeseries Baseline and Upgrade Data Example Jupyter notebook for pulling timeseries aggregate files from the OEDI data lake for a certain geography and housing type, and then plots a comparison.