Reset freqmax when switching datasets