Added functionality to sort by words occuring most frequently.