Updated function freqspec