Insights - How to Create Custom Buckets (Histogram)

Updated 10 months ago by Elena Yurkova

How to create customer buckets (Histogram)

Business value: Create a widget to visualize distribution.

Example: We have opportunities with different revenue amounts and we would like to know how many opportunities are under $2,000, between $2000 and $5,000 etc. Let's say our chart will have 5 following buckets:

$1 - 1,000

$1,001 - 5,000

$5,001 - 10,000

$10,001 - 20,000

$20,001 +

The desired outcome is to see many opportunities we have in each bucket or instead of the chart on the left, you can create the chart on the right widget.

The same method could be applied for pie or bar charts.
  1. Start by adding the value field you would like to count. In this scenario, it is the Identification field from the Opportunities table.

The formula in the Value field is now COUNT(Identification).

  1. Go to edit mode and pick the Column Chart from the drop-down list.
  1. Leave Categories blank.
  2. Now, let's add a filtering field Revenue to the formula. Remember that the filtering field must always be located after the main value field and separated by a comma. In our case, we want to count the number of Opportunities and filter on revenue, so the syntax will be (COUNT([Identification]),[Revenue])
  3. Inside the formula, click on [Revenue] and choose Filter.
  1. Pick the range of the first bucket and click OK.
  1. Now duplicate the Value field four times (right Click followed by 'Duplicate') and name the buckets accordingly.
  1. Now there are 5 bars on the chart, but the data is only correct in the first one. Click on the pencil icon to modify the filter for the second bucket 2001-5000 as explained in steps 5 and 6.
  2. Follow the logic above and go through all buckets to adjust filtering values in the formulas.

All done. Now we we can see that the most of our Opportunities are between $10,000 and $20,000.

How did we do?