pudl.extract.eia860#

Retrieve data from EIA Form 860 spreadsheets for analysis.

This modules pulls data from EIA’s published Excel spreadsheets.

This code is for use analyzing EIA Form 860 data.

Module Contents#

Classes#

Extractor

Extractor for the excel dataset EIA860.

Functions#

extract_eia860(context, raw_eia860__all_dfs)

Extract raw EIA data from excel sheets into dataframes.

Attributes#

pudl.extract.eia860.logger[source]#
class pudl.extract.eia860.Extractor(*args, **kwargs)[source]#

Bases: pudl.extract.excel.ExcelExtractor

Extractor for the excel dataset EIA860.

process_raw(df, page, **partition)[source]#

Apply necessary pre-processing to the dataframe.

  • Rename columns based on our compiled spreadsheet metadata

  • Add report_year if it is missing

  • Add a flag indicating if record came from EIA 860, or EIA 860M

  • Fix any generator_id values with leading zeroes.

static get_dtypes(page, **partition)[source]#

Returns dtypes for plant id columns.

pudl.extract.eia860.raw_table_names = ('raw_eia860__boiler_cooling', 'raw_eia860__boiler_generator_assn', 'raw_eia860__boiler_info',...[source]#
pudl.extract.eia860.raw_eia860__all_dfs[source]#
pudl.extract.eia860.extract_eia860(context, raw_eia860__all_dfs)[source]#

Extract raw EIA data from excel sheets into dataframes.

Parameters:

context – dagster keyword that provides access to resources and config.

Returns:

A tuple of extracted EIA dataframes.