import { identity } from "@thi.ng/compose/identity";
import { count } from "./count.js";
import { groupByMap } from "./group-by-map.js";
import { $$reduce } from "./reduce.js";
function frequencies(...args) {
  return $$reduce(frequencies, args) || groupByMap({ key: args[0] || identity, group: count() });
}
export {
  frequencies
};
