Mathematica > Core Language > List Manipulation > Math & Counting Operations on Lists >
Mathematica > Data Manipulation > Handling Arrays of Data > Math & Counting Operations on Lists >

Commonest

Commonest[list]
gives a list of the elements that are the most common in list.
Commonest[list, n]
gives a list of the n most common elements in list.
  • When several elements occur with equal frequency, Commonest[list, ...] picks first the ones that occur first in list.
  • Commonest[list, n] returns the n commonest elements in the order they appear in list.
New in 6
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team