def rates_for_yr(rates_all_years, sim_year):
    """
    Filter specific rates for a given year

    Parameters
    ----------
    rates_all_years : pandas DataFrame
        rates, to be filtered by year
    sim_year : int
        year being simulated

    Returns
    -------
    pop_w_rates : pandas DataFrame
        rates for a given year

    """
    rates_yr = rates_all_years[rates_all_years['yr'] == sim_year]
    return rates_yr