Sum of coding variable by using Index and Match

greenka

New Member
Joined
Mar 23, 2018
Messages
3
Dear all,

This is my first time here. Could you please advice me with this question? I already try to search but couldn't find the answer.

Each worksheet called "Project 1, 2, 3, ...., 10" and have 5 questions which each question has drop down to choose 3 variables (YES-2, PARTIAL-1, NO-0). And I want to sum all of 15 questions in another worksheet called "Summary" - which has 10 projects in total.

What I did now is, I recode (YES-2, PARTIAL-1, NO-0) by using function INDEX and MATCH in "Data" worksheet in table below.

[TABLE="width: 500"]
<tbody>[TR]
[TD][/TD]
[TD]A
[/TD]
[TD] B
[/TD]
[TD] C
[/TD]
[/TR]
[TR]
[TD]7
[/TD]
[TD]Code
[/TD]
[TD] Value
[/TD]
[TD] Value_Recode
[/TD]
[/TR]
[TR]
[TD]8
[/TD]
[TD]YES-2
[/TD]
[TD] 2
[/TD]
[TD] 2 =INDEX($B$8:$B$10,MATCH(A8,$A$8:$A$10,0))
[/TD]
[/TR]
[TR]
[TD]9
[/TD]
[TD]PARTIAL-1
[/TD]
[TD] 1
[/TD]
[TD] 1 = INDEX($B$8:$B$10,MATCH(A9,$A$8:$A$10,0))
[/TD]
[/TR]
[TR]
[TD]10
[/TD]
[TD]NO-0
[/TD]
[TD] 0
[/TD]
[TD] 0 = INDEX($B$8:$B$10,MATCH(A10,$A$8:$A$10,0))
[/TD]
[/TR]
</tbody>[/TABLE]


As I mentioned, each worksheet called "Project 1, 2, 3, ...., 10" and have 5 questions which each question has drop down to choose 3 variables (YES-2, PARTIAL-1, NO-0). And I want to sum all 15 questions in "Summary" worksheet.

So, in "Summary" worksheet, I created the formula for Project 1 like this =SUM(INDEX(Data!$B$8:$B$10,MATCH('Project 1'!C1,Data!$A$8:$A$10,0))+INDEX(Data!$B$8:$B$10,MATCH('Project 1'!C2,Data!$A$8:$A$10,0))+INDEX(Data!$B$8:$B$10,MATCH('Project 1'!C3,Data!$A$8:$A$10,0))+INDEX(Data!$B$8:$B$10,MATCH('Project 1'!C4,Data!$A$8:$A$10,0))+INDEX(Data!$B$8:$B$10,MATCH('Project 1'!C5,Data!$A$8:$A$10,0)))

If you can see in the formula that, only the cells that I highlighted and underlined. I'm wondering are there any easier function that I can sum these 5 cells (C1-C5)?

I tried all sumif, sumproduct but doesn't work. I don't know how to use VBA. Could you please help me? Really appreciated.

Many thanks.
Green:)
 

Excel Facts

Copy formula down without changing references
If you have =SUM(F2:F49) in F50; type Alt+' in F51 to copy =SUM(F2:F49) to F51, leaving the formula in edit mode. Change SUM to COUNT.
Hi Aladin,

Thank you very much to stop by my questions. I tried to attach the screenshot but doesn't work. So, I will type it here.

Worksheet "Project 1, Project 2, 3, ...., 10" have same questions (actually total is 13 questions).

No. Questions Score (this column you can choose drop down for YES-2, PARTIAL-1, NO-0)
Topic A
1. It is project clearly stated? xx (choose from drop down)
2. Does the agency search for budget? xx (choose from drop down)
3. ...
4. ...
Topic B
5.
6.
7.
8.
9.
Topic C
10.
11.
12.
13. ....

So, in "Summary" worksheet, I want to sum score of Topic A, Topic B, Topic C of Project 1, Project 2, 3, 4, 5, ........10 for each row.

Please let me know if you are not clear. Thank you very much for your help.

Green
 
Upvote 0

Forum statistics

Threads
1,224,823
Messages
6,181,170
Members
453,021
Latest member
Justyna P

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