Skip to contents

Build a panel

One call returns a documented state-by-year panel.

build_panel()
Build a state-year energy-economy panel

RPS stringency

Coded Renewable Portfolio Standard rules and annual stringency measures.

rps_rules()
Coded Renewable Portfolio Standard rules
rps_stringency()
Annual RPS stringency indices
fetch_rps()
Get RPS rule coding from the package or a URL

Download data

Fetch and cache data from the EIA, BEA and Census APIs.

fetch_eia()
Download state data from the EIA API
fetch_bea()
Download data from the BEA API
fetch_census()
Download state data from the Census Bureau API
rps_cache_dir() rps_cache_list() rps_cache_clear()
Manage the download cache

Harmonise

Align state identifiers, units and price bases across sources.

harmonise_states()
Harmonise state identifiers
us_states()
US states and the District of Columbia
deflate()
Convert nominal values to real values
convert_units() convert_units_available()
Convert between units

Document and cite

codebook()
Variable codebook
cite_sources()
Citations for the data sources used

Estimate and export

as_pdata()
Convert a panel for estimation packages
export_panel()
Export a panel to CSV, Stata or Parquet