OK, I'm no math expert so there's invariably a better approach but for the sake of demo let's do this...
Insert a new sheet into your file, entitled "ADJUST", into which place the below (M/G being A1, 1 to 10 in B1:K1, 0.1 to 0.9 in A2:10, 1's in matrix as appropriate)
Back to sheet... to keep things as simple as possible... using our existing setup such that B1 is calculating our COUNT of numbers / 10 and C1:L1 our 10 Averages then I would advise the following to account for possibility of uneven groups:
this gives us the decimal remainder
(ie * 10 how many rows preventing even grouping)
then leaving O1 blank (important) you can use formulae in P1 onwards to determine rows per group utilising your ADJUST table:
We can now revise our approach in C1:L1 to utilise the data generated in P1:Y1 (using O1 also) such that:
As you alter the rows you should find the Averages adjust per rows in each group - if you wish to alter the distribution of the excess rows based on the remainder you can simply alter the 1's in the ADJUST matrix accordingly.
Does that help ?
(as I say I suspect there are preferable approaches to this one...)
Bookmarks