Sep 30 2021 07:17 PM
I am wondering if anyone can help me with an excel script..
I have a spreadsheet capturing a name (column A) and number (column B) in descending order from greatest to least
these are blinded doctors and their patient number (I attached dummy data for reference)
I am hoping for a formula (which would go in column 3) which will sum the entire set (42,387), divide it by 10 (4238.7) (this will provide how many patients belong in each 'decile') , then be able to add up the number of rows it takes to reach the decile (AKA how many rows to reach and not surpass 4238.7)...then every set of names is labeled 10, 9, 8... all the way to 1
Let me know your thoughts and thank you
K
Oct 01 2021 02:02 AM
In C2, enter the start value 10.
In C3, enter the formula
=C2-(SUM($B$2:$B3)>(11-C2)*$F$4)
Fill down to the last row with data.