def year_from_operating_datetime(df):
    """Add a 'year' column based on the year in the operating_datetime.

    Args:
        df (pandas.DataFrame): A DataFrame containing EPA CEMS data.

    Returns:
        pandas.DataFrame: A DataFrame containing EPA CEMS data with a 'year'
        column.

    """
    df['year'] = df.operating_datetime_utc.dt.year
    return df