Average score for each project by person

kadam

New Member
Joined
Aug 29, 2008
Messages
5
I want to calculate average "Estimated Effort" for project associated to each EVP.

For example, Wilber has two projects, one has an estimated effort of 2 and the other one is a 3, so I want to create a table that pulls the information for Wilbert and states looks something like this:


Report
[TABLE="width: 355"]
<colgroup><col><col><col></colgroup><tbody>[TR]
[TD="align: center"]EVP[/TD]
[TD="align: center"]Num of Projects[/TD]
[TD="align: center"]Average Est Effort[/TD]
[/TR]
[TR]
[TD]Mike[/TD]
[TD="align: right"]2[/TD]
[TD="align: right"]4[/TD]
[/TR]
[TR]
[TD]Wilber[/TD]
[TD="align: right"]2[/TD]
[TD="align: right"]2.25[/TD]
[/TR]
[TR]
[TD]Hank[/TD]
[TD="align: right"]3[/TD]
[TD="align: right"]1[/TD]
[/TR]
</tbody>[/TABLE]



Here is the source table:
[TABLE="width: 640"]
<colgroup><col><col><col><col><col></colgroup><tbody>[TR]
[TD="align: center"]Project Title[/TD]
[TD="align: center"]EVP[/TD]
[TD="align: center"]Est. Project Size (T-shirt Sizing)[/TD]
[TD="align: center"]Application Dependencies[/TD]
[TD="align: center"]Estimated Effort[/TD]
[/TR]
[TR]
[TD]Remove Sybase (Architecture)[/TD]
[TD]Mike[/TD]
[TD]4[/TD]
[TD]4[/TD]
[TD]4[/TD]
[/TR]
[TR]
[TD]Pre-Requisites to Conversion to Oracle[/TD]
[TD]Wilber[/TD]
[TD]3[/TD]
[TD]1[/TD]
[TD]2[/TD]
[/TR]
[TR]
[TD]Quote Replacement[/TD]
[TD]Mike[/TD]
[TD]4[/TD]
[TD]4[/TD]
[TD]4[/TD]
[/TR]
[TR]
[TD]OEM Lock Down[/TD]
[TD]Wilber[/TD]
[TD]2[/TD]
[TD]3[/TD]
[TD]3[/TD]
[/TR]
[TR]
[TD]Locker Pickup P2[/TD]
[TD]Hank[/TD]
[TD]1[/TD]
[TD]1[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD]POS Restriction to Purchase when BSS has a STD xref.[/TD]
[TD]Hank[/TD]
[TD]1[/TD]
[TD]1[/TD]
[TD]1[/TD]
[/TR]
[TR]
[TD]Modify POS New Store Database build to support version 7.3[/TD]
[TD]Hank[/TD]
[TD]1[/TD]
[TD]1[/TD]
[TD]1[/TD]
[/TR]
</tbody>[/TABLE]
 

Excel Facts

How to create a cell-sized chart?
Tiny charts, called Sparklines, were added to Excel 2010. Look for Sparklines on the Insert tab.
with PowerQuery aka Get&Transform

[Table="width:, class:head"]
[tr=bgcolor:#FFFFFF][td=bgcolor:#70AD47]EVP[/td][td=bgcolor:#70AD47]Count[/td][td=bgcolor:#70AD47]Avg[/td][/tr]

[tr=bgcolor:#FFFFFF][td=bgcolor:#E2EFDA]Mike[/td][td=bgcolor:#E2EFDA]
2​
[/td][td=bgcolor:#E2EFDA]
4​
[/td][/tr]

[tr=bgcolor:#FFFFFF][td]Wilber[/td][td]
2​
[/td][td]
2.5​
[/td][/tr]

[tr=bgcolor:#FFFFFF][td=bgcolor:#E2EFDA]Hank[/td][td=bgcolor:#E2EFDA]
3​
[/td][td=bgcolor:#E2EFDA]
1​
[/td][/tr]
[/table]


Code:
[SIZE=1]let
    Source = Excel.CurrentWorkbook(){[Name="Table1"]}[Content],
    #"Changed Type" = Table.TransformColumnTypes(Source,{{"Project Title", type text}, {"EVP", type text}, {"Est. Project Size (T-shirt Sizing)", Int64.Type}, {"Application Dependencies", Int64.Type}, {"Estimated Effort", Int64.Type}}),
    #"Grouped Rows" = Table.Group(#"Changed Type", {"EVP"}, {{"Count", each Table.RowCount(_), type number}, {"Avg", each List.Average([Estimated Effort]), type number}})
in
    #"Grouped Rows"[/SIZE]

is that what you want?
 
Upvote 0
Yes, that is the results I'm looking for. I'm not familiar with Power Query but I'm sure I can find some tutorials on how to do it.

Thank you
 
Upvote 0
Please forgive me if I am missing a critical detail, but why not just use AVERAGEIF where your (test) range is your EVP, your criteria is the name of the EVP, and the average range is the Estimated Effort column?

[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD][/TD]
[TD]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TD]13[/TD]
[TD]Hank[/TD]
[TD]3[/TD]
[TD]1[/TD]
[TD][/TD]
[TD][/TD]
[/TR]
</tbody>[/TABLE]

Where the formula in cells C11:C13 is =AVERAGEIF($B$2:$B$8,B11,$E$2:$E$8)
 
Last edited:
Upvote 0
That makes sense too. I tried to use an AverageIf statement but couldn't get it to work, obviously I wasn't doing it right and no help menus were very helpful. Thank you.
 
Upvote 0
AVERAGEIF is pretty straightforward. The arguments are, in order:

Range: the range where you want to test on some condition. In your case, it will be the range of cells that contain your EVP names.

Criteria: the test. If you are testing for anything otherwise than equality, you have to put the test (<,>,<=,>=,<>) and the test value, inside quotes. For example, if your condition was >5, your criteria arg would be “>5”.

Since you are testing for equality, simply using the cell reference that has the value you are looking to test on suffices.

Average Range: this is an optional arg and is used when the values you want to average are not in the range you are testing on. In your specific case, the range of cells containing the estimated effort.

Using absolute and relative cell referencing correctly should allow you to copy and paste the formula up/down/left/right as needed.

If you’re still not sure what do do, just google AVERAGEIF Anne Excel is Fun.
 
Upvote 0

Forum statistics

Threads
1,223,231
Messages
6,170,885
Members
452,364
Latest member
springate

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