Marc Wilson
New Member
- Joined
- Jul 7, 2015
- Messages
- 1
Excel ver. 2010, 32-bit
OS Windows 7 Pro, 32-bit, Service pack 1
Normally I can find what I'm looking for online or on the boards but this one has me stumped. My actual sheet has hundreds of rows and columns but here is a simple example illustrating my challenge:
Below is a table of students and their test scores and quiz scores this year. I want a formula that will return an average of the 3 most recent test scores for each student.
[TABLE="class: grid, width: 500, align: center"]
<tbody>[TR]
[TD]Test/Quiz[/TD]
[TD]Michael[/TD]
[TD]David[/TD]
[TD]Cara[/TD]
[TD]Tyshawn[/TD]
[/TR]
[TR]
[TD]Test 5[/TD]
[TD]90[/TD]
[TD]91[/TD]
[TD][/TD]
[TD]95[/TD]
[/TR]
[TR]
[TD]Quiz 5[/TD]
[TD]88[/TD]
[TD]72[/TD]
[TD][/TD]
[TD]90[/TD]
[/TR]
[TR]
[TD]Test 4[/TD]
[TD]88[/TD]
[TD]82[/TD]
[TD]85[/TD]
[TD]82[/TD]
[/TR]
[TR]
[TD]Quiz 4[/TD]
[TD]92[/TD]
[TD]93[/TD]
[TD]79[/TD]
[TD]79[/TD]
[/TR]
[TR]
[TD]Test 3[/TD]
[TD][/TD]
[TD]73[/TD]
[TD]86[/TD]
[TD]70[/TD]
[/TR]
[TR]
[TD]Quiz 3[/TD]
[TD][/TD]
[TD]75[/TD]
[TD]90[/TD]
[TD]75[/TD]
[/TR]
[TR]
[TD]Test 2[/TD]
[TD]75[/TD]
[TD][/TD]
[TD]88[/TD]
[TD]90[/TD]
[/TR]
[TR]
[TD]Quiz 2[/TD]
[TD]68[/TD]
[TD][/TD]
[TD]85[/TD]
[TD]79[/TD]
[/TR]
[TR]
[TD]Test 1[/TD]
[TD]85[/TD]
[TD][/TD]
[TD]91[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Quiz 1[/TD]
[TD]82[/TD]
[TD][/TD]
[TD]90[/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
I have bolded the test scores since that's all we're interested in. The ideal formula will be something I can fill right as far as I need to go (I understand about relative references so no need to add the $'s).
The correct answers for the formula will be:
Michael: 84.33
David: 82.00
Cara: 86.33
Tyshawn: 82.33
As you can see, I have two challenges.
First, there are blank cells to deal with, and the blanks are not distributed evenly across rows, meaning that the students have different combinations of rows representing the three most recent tests.
Second, there is quiz data interspersed that I don't want to capture, so I can't just use a range of contiguous cells.
The formula I'm looking for would look just at rows 2, 4, 6, 8, and 10 and return the average of the uppermost three cells which contain values.
As I mentioned, my actual sheet is much more complicated, so adjusting the cells in the formula for each column, and updating those adjustments whenever I add new rows, isn't feasible.
Any help would be greatly appreciated. Thanks!
OS Windows 7 Pro, 32-bit, Service pack 1
Normally I can find what I'm looking for online or on the boards but this one has me stumped. My actual sheet has hundreds of rows and columns but here is a simple example illustrating my challenge:
Below is a table of students and their test scores and quiz scores this year. I want a formula that will return an average of the 3 most recent test scores for each student.
[TABLE="class: grid, width: 500, align: center"]
<tbody>[TR]
[TD]Test/Quiz[/TD]
[TD]Michael[/TD]
[TD]David[/TD]
[TD]Cara[/TD]
[TD]Tyshawn[/TD]
[/TR]
[TR]
[TD]Test 5[/TD]
[TD]90[/TD]
[TD]91[/TD]
[TD][/TD]
[TD]95[/TD]
[/TR]
[TR]
[TD]Quiz 5[/TD]
[TD]88[/TD]
[TD]72[/TD]
[TD][/TD]
[TD]90[/TD]
[/TR]
[TR]
[TD]Test 4[/TD]
[TD]88[/TD]
[TD]82[/TD]
[TD]85[/TD]
[TD]82[/TD]
[/TR]
[TR]
[TD]Quiz 4[/TD]
[TD]92[/TD]
[TD]93[/TD]
[TD]79[/TD]
[TD]79[/TD]
[/TR]
[TR]
[TD]Test 3[/TD]
[TD][/TD]
[TD]73[/TD]
[TD]86[/TD]
[TD]70[/TD]
[/TR]
[TR]
[TD]Quiz 3[/TD]
[TD][/TD]
[TD]75[/TD]
[TD]90[/TD]
[TD]75[/TD]
[/TR]
[TR]
[TD]Test 2[/TD]
[TD]75[/TD]
[TD][/TD]
[TD]88[/TD]
[TD]90[/TD]
[/TR]
[TR]
[TD]Quiz 2[/TD]
[TD]68[/TD]
[TD][/TD]
[TD]85[/TD]
[TD]79[/TD]
[/TR]
[TR]
[TD]Test 1[/TD]
[TD]85[/TD]
[TD][/TD]
[TD]91[/TD]
[TD][/TD]
[/TR]
[TR]
[TD]Quiz 1[/TD]
[TD]82[/TD]
[TD][/TD]
[TD]90[/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]
I have bolded the test scores since that's all we're interested in. The ideal formula will be something I can fill right as far as I need to go (I understand about relative references so no need to add the $'s).
The correct answers for the formula will be:
Michael: 84.33
David: 82.00
Cara: 86.33
Tyshawn: 82.33
As you can see, I have two challenges.
First, there are blank cells to deal with, and the blanks are not distributed evenly across rows, meaning that the students have different combinations of rows representing the three most recent tests.
Second, there is quiz data interspersed that I don't want to capture, so I can't just use a range of contiguous cells.
The formula I'm looking for would look just at rows 2, 4, 6, 8, and 10 and return the average of the uppermost three cells which contain values.
As I mentioned, my actual sheet is much more complicated, so adjusting the cells in the formula for each column, and updating those adjustments whenever I add new rows, isn't feasible.
Any help would be greatly appreciated. Thanks!