Creating Bins based on Average Value *AND* Count

ExcelChampion

Well-known Member
Joined
Aug 12, 2005
Messages
976
Racking my brain on this one...

creating a table of 1-10 buckets to show the average of values that fall in those buckets. The buckets are simply a min as the lowest, max as the highest, and the rest is equally distributed between the min and max.

The issue is that when I also do a count of the values that fall in those buckets, I'm getting a result where 99.9% of values fall in to the min bucket.

I'd like to create the buckets using most of the data. So, my buckets would really be from 0 to 227, for example.

Code:
       Bucket  Avg Value  Count
Min	0	-1.2%	  26031
	227	-0.7%	  110
	455	-1.6%	  37
	682	1.1%	  33
	909	-11.8%	  12
	1,137	-10.5%	  5
	1,364	1.2%	  4
	1,591	25.2%	  1
	1,818	0.0%	  1
	2,046	-2.2%	  2
Max	2,273
 
Last edited:

Excel Facts

How to fill five years of quarters?
Type 1Q-2023 in a cell. Grab the fill handle and drag down or right. After 4Q-2023, Excel will jump to 1Q-2024. Dash can be any character.
So you have taken the min and max values of your data then equally distributed some intervals to count your values into? What formula are you using to produce these counts?
 
Upvote 0
have you tried somethign like this:
Code:
=AVERAGEIFS($A$2:$A$960,$A$2:$A$960,">" & PERCENTILE($A$2:$A$960,0.1),$A$2:$A$960,"<" &PERCENTILE($A$2:$A$960,0.2))
 
Upvote 0

Forum statistics

Threads
1,214,866
Messages
6,121,996
Members
449,060
Latest member
mtsheetz

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top