Grade sheet which discards empty cells

MaddogJason

New Member
Joined
Jan 30, 2021
Messages
24
Office Version
  1. 365
Platform
  1. Windows
A small grade spreadsheet challenge to you rockstars.
This seems like an easy one, I thought I would be able to solve it, but....
Row 2 is how much each task weighs, in row 1 you see the percentage.
John has done three tasks columns B, C, D, He gets the grade in column E based on the average that takes the weight of the task in mind. Works perfectly.
Lisa has not done the task in Column C and I need a function that discards that fact, so she should get grade 5. So when any task is missing it will not take it into account in the calculation.
As a bonus, it would be great to have a function that could easily be adjusted if a new column (task) would be added.


CocoaBreak3.0.xlsm
ABCDE
1%252550
2Weight112
3Task 1HomeworkTest
4John6455.00
5Lisa 553.75
week 3
Cell Formulas
RangeFormula
B1:D1B1=(100*B2)/($B$2+$C$2+$D$2)
E4:E5E4=((B4*$B$2)+(C4*$C$2)+(D4*$D$2))/(SUM($B$2:$D$2))
 

Excel Facts

What is the last column in Excel?
Excel columns run from A to Z, AA to AZ, AAA to XFD. The last column is XFD.
Hi,

You can change the SUM to SUMIF:

Book3.xlsx
ABCDE
1%252550
2Weight112
3Task 1HomeworkTest
4John6455
5Lisa 555
Sheet836
Cell Formulas
RangeFormula
B1:D1B1=B2/SUM($B2:$D2)*100
E4:E5E4=(B4*B$2+C4*C$2+D4*D$2)/SUMIF(B4:D4,"<>",B$2:D$2)
 
Upvote 0
Solution
One thought -- is this correct?

Code:
=SUM($B$2:$D$2*B4:D4)/(SUM($B$2:$D$2*ISNUMBER(B4:D4)))

Book1 (version 1).xlsb
ABCDE
1%252550
2Weight112
3Task 1HWTest
4John6455
5Lisa555
6Jason102016.66667
Sheet6
Cell Formulas
RangeFormula
E4:E6E4=SUM($B$2:$D$2*B4:D4)/(SUM($B$2:$D$2*ISNUMBER(B4:D4)))
 
Upvote 0
As a bonus, it would be great to have a function that could easily be adjusted if a new column (task) would be added.

Adding a SUMPRODUCT option:

Book3.xlsx
ABCDEF
1%252550
2Weight112
3Task 1HomeworkTest
4John64555
5Lisa 5555
Sheet836
Cell Formulas
RangeFormula
B1:D1B1=B2/SUM($B2:$D2)*100
E4:E5E4=(B4*B$2+C4*C$2+D4*D$2)/SUMIF(B4:D4,"<>",B$2:D$2)
F4:F5F4=SUMPRODUCT(B$2:D$2*B4:D4)/SUMIF(B4:D4,"<>",B$2:D$2)
 
Upvote 0
A couple of other possibilities.
+Fluff 1.xlsm
ABCDEF
1%252550
2Weight112
3Task 1HomeworkTest
4John64555
5Lisa 5555
6Pete655.255.375
Master
Cell Formulas
RangeFormula
B1:D1B1=(100*B2)/($B$2+$C$2+$D$2)
E4:E6E4=SUMPRODUCT(IF(B4:D4="",5,B4:D4),B$2:D$2)/SUM(B$2:D$2)
F4:F6F4=SUMPRODUCT(IF(B4:D4="",AVERAGE(B4:D4),B4:D4),B$2:D$2)/SUM(B$2:D$2)
 
Upvote 0
THANK YOU ALL FOR YOUR HELP!!!!
It always amazes me how quickly I get answers in this forum. Makes me wonder why I even bother to try it myself... When I see the functions I get them, but figuring them out on my own still seems next to impossible.
Below are the functions that worked.
Fluff's functions seem to get confused with the average and does not take into account which specific tasks has what specific weight.
Now the question is which one works the best when adding a column? Perhaps I need to record a macro to include the new column. The other option would be to put the function in column C and then just widen the range by a lot and then basically be able to just add tasks if need be.
Thank you once again for all the help and good solutions. I will obviously take all the credit for this success and brag about my mad Excel skills!


CocoaBreak3.0.xlsm
ABCDE
1%292943
2Weight223
3Task 1HomeworkTest
4Fluff 1465.14
5Fluff 2465.14
6Jtakw44.6765.05
7Paul465.20
8Kwever465.20
9Jtakw465.20
10Maddog465.20
week 3
Cell Formulas
RangeFormula
B1:D1B1=B2/SUM($B2:$D2)*100
E4E4=SUMPRODUCT(IF(B4:D4="",AVERAGE(B4:D4),B4:D4),B$2:D$2)/SUM(B$2:D$2)
E5E5=SUMPRODUCT(IF(B5:D5="",5,B5:D5),B$2:D$2)/SUM(B$2:D$2)
E6E6=SUMPRODUCT(B$2:D$2*B6:D6)/SUMIF(B6:D6,"<>",B$2:D$2)
E7,E9E7=(B7*B$2+C7*C$2+D7*D$2)/SUMIF(B7:D7,"<>",B$2:D$2)
E8E8=SUM($B$2:$D$2*B8:D8)/(SUM($B$2:$D$2*ISNUMBER(B8:D8)))
E10E10=((B10*$B$2)+(D10*$D$2))/(SUM($B$2+$D$2))
 
Upvote 0
THANK YOU ALL FOR YOUR HELP!!!!
It always amazes me how quickly I get answers in this forum. Makes me wonder why I even bother to try it myself... When I see the functions I get them, but figuring them out on my own still seems next to impossible.
Below are the functions that worked.
Fluff's functions seem to get confused with the average and does not take into account which specific tasks has what specific weight.
Now the question is which one works the best when adding a column? Perhaps I need to record a macro to include the new column. The other option would be to put the function in column C and then just widen the range by a lot and then basically be able to just add tasks if need be.
Thank you once again for all the help and good solutions. I will obviously take all the credit for this success and brag about my mad Excel skills!


CocoaBreak3.0.xlsm
ABCDE
1%292943
2Weight223
3Task 1HomeworkTest
4Fluff 1465.14
5Fluff 2465.14
6Jtakw44.6765.05
7Paul465.20
8Kwever465.20
9Jtakw465.20
10Maddog465.20
week 3
Cell Formulas
RangeFormula
B1:D1B1=B2/SUM($B2:$D2)*100
E4E4=SUMPRODUCT(IF(B4:D4="",AVERAGE(B4:D4),B4:D4),B$2:D$2)/SUM(B$2:D$2)
E5E5=SUMPRODUCT(IF(B5:D5="",5,B5:D5),B$2:D$2)/SUM(B$2:D$2)
E6E6=SUMPRODUCT(B$2:D$2*B6:D6)/SUMIF(B6:D6,"<>",B$2:D$2)
E7,E9E7=(B7*B$2+C7*C$2+D7*D$2)/SUMIF(B7:D7,"<>",B$2:D$2)
E8E8=SUM($B$2:$D$2*B8:D8)/(SUM($B$2:$D$2*ISNUMBER(B8:D8)))
E10E10=((B10*$B$2)+(D10*$D$2))/(SUM($B$2+$D$2))
 
Upvote 0

Forum statistics

Threads
1,214,983
Messages
6,122,583
Members
449,089
Latest member
Motoracer88

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