That's correct....those sections would look like this:
{1,2,3,4,5,6,7,8,9}
MIN(9,SUMPRODUCT
However, as the number of items you want to include increases, this
variation of the sequential list is more compact:
ROW($1:$9)..........replaces {1,2,3,4,5,6,7,8,9}
Just don't add rows above Row_1 or between rows 1 and 9.
If that's a risk, there are other techniques:
ROW(INDEX($A:$A,1):INDEX($A:$A,9))
or
ROW(INDIRECT("1:9"))
BTW.....Thanks for the feedback!
***********
Regards,
Ron
XL2002, WinXP
Rack Pack said:
Just tried it and it works like a charm. Now my only question is if I wanted
to change from the last 6 to last 9 for example, what would I change in the
formula. Right now I'm thinking that {1,2,3,4,5,6} and (6,SUMPRODUCT...
would be the sections to change. I don't think I have had enough coffee yet
this morning to really analyze it.
Ron Coderre said:
With
A2: (a name)
B2:J2 (scores with some blank cells)
This ARRAY FORMULA averages the last 6 non-blank cells and if there are less
than 6 scores, it averages the available scores:
K2:
=SUMPRODUCT(ISNUMBER(MATCH(COLUMN(B2:J2),LARGE(((B2:J2<>0)*COLUMN(B2:J2)),{1,2,3,4,5,6}),0))*B2:J2)/MIN(6,SUMPRODUCT(--(B2:J2<>0)))
Note: For array formulas, hold down [Ctrl] [Shift] when you press [Enter],
instead of just pressing [Enter].
Is that something you can work with?
***********
Regards,
Ron
XL2002, WinXP
:
I manage a sports league with a handicap format. Each individual may not
play each week. I need to select the last 6 entries in a row or column to
enclude in my handicap formula. As my columns are headed by the date, there
are blanks. The worksheet could be converted to rows if neccesary. Any
idesa anyone?
Thanks for any help in advance,