fix_5B integrate sort function by frequency

you need to reverse also I think