The most frequent values (all of them, in increasing order) and their frequency. Equivalent to DescTools::Mode() in R. Missing values are dropped; value is [NaN] and frequency NaN when every value occurs once.
DescTools::Mode()
value
[NaN]
frequency
How often each of them occurs (NaN when every value occurs once).
The most frequent values, in increasing order ([NaN] when every value occurs once).
modes([1, 2, 2, 3, 3, 4]); // { value: [2, 3], frequency: 2 } Copy
modes([1, 2, 2, 3, 3, 4]); // { value: [2, 3], frequency: 2 }
The most frequent values (all of them, in increasing order) and their frequency. Equivalent to
DescTools::Mode()in R. Missing values are dropped;valueis[NaN]andfrequencyNaN when every value occurs once.