add withFrequency method