Try something like:
Search for AccountingEntries: Grouped by type: aggregate Count: sorted by Count: first Item
And
Search for AccountingEntries: Grouped by Type: aggregate Sum of revenue: sorted by Revenue: first item