Finding Average value based on multiple criteria (multiple values)

bootstrap

New Member
Joined
Oct 16, 2014
Messages
3
Hi Excel Pros,

Table:
Name Price New/Old
A 10 Y
A 20 N
B 35 Y
B 45 Y
C 50 N
C 60 Y
If I want to find: The average price when name = A and New/Old = Y:

IFERROR(AVERAGEIFS($B$2:$B$7, $A$2:$A$7, "A", $C$2:$C$7, "Y"),"") = 10


<tbody>
</tbody>
This is working perfectly

However, I don't know how to find: The average price when name = A or B and New/Old = Y.
The correct answer is supposed to be: (10+35+45)/3 = 30

Thanks in advance!
 

Excel Facts

Square and cube roots
The =SQRT(25) is a square root. For a cube root, use =125^(1/3). For a fourth root, use =625^(1/4).
try

Code:
=SUM(SUMIFS(B2:B7,C2:C7,"Y",A2:A7,{"A","B"}))/SUM(COUNTIFS(C2:C7,"Y",A2:A7,{"A","B"}))
 
Upvote 0
Thanks everyone for reading this post! I have the solution already. Please do not waste your time on this anymore!
 
Upvote 0

Forum statistics

Threads
1,216,103
Messages
6,128,854
Members
449,472
Latest member
ebc9

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