Count by group
The Count by group step counts the number of rows that exist for each unique value or combination of values in one or more columns. This step is similar to the COUNTIF function in Excel.
Watch this Parabola University video for a quick walkthrough of the Count by group step.
Input/output
Our input data is a list of ecommerce orders, including detailed data about items ordered.
![](https://cdn.prod.website-files.com/663559c9207f91d5a1ba91e4/66c8dedff68f8d21ce624876_66c8dafd8c921640da350286_Screenshot%25202024-08-23%2520at%252011.54.38%25E2%2580%25AFAM.png)
We want to know how many of each SKU was sold. With the step set up and data flowing through it, we can see that we our most popular item was SKU #1586082 with 11 items sold.
![](https://cdn.prod.website-files.com/663559c9207f91d5a1ba91e4/66c8dedff68f8d21ce624860_66c8db4b7dbaeaea416e3605_Screenshot%25202024-08-23%2520at%252011.55.50%25E2%2580%25AFAM.png)
Default settings
By default, this step will count every row as unique and display a 'Count' column with the same value as the number of rows in your input table.
![](https://cdn.prod.website-files.com/663559c9207f91d5a1ba91e4/66c7d2b8d196c0a78a300cac_65556c133918e76198550883_Screenshot%25202023-11-15%2520at%25205.10.32%2520PM.png)
Custom settings
To customize these default settings, you'll first select a column or multiple columns you'd like to count unique values in. Then, you'll title your new counting column.
Above, we wanted to count groups in a single column, so we selected 'SKU' from the dropdown and named the new column 'Count'. You can also add multiple columns if you want to count unique values for the combinations of those column values.
For example, if we want to count sizes sold of each item type, we can select 'Product Title' and 'Variant Title 2' (item sizes) from the dropdown to see these updated results. The results below show us that we sold significantly more small than medium women's athleisure tops.
![](https://cdn.prod.website-files.com/663559c9207f91d5a1ba91e4/66c8dedff68f8d21ce62486c_66c8dc9ec61bfd4fcadfeebf_Screenshot%25202024-08-23%2520at%252011.59.51%25E2%2580%25AFAM.png)