Add check for consistency of frequency and time_period [skip ci]