How to calculate an average between certain cells in a column that corespond to cells in a different column?

时间:2016-02-12 20:07:56

标签: excel

I'm having trouble explaining exactly what I need, it'll be easier if I just give an example. Please keep in mind I'm not a programmer of any sorts, I'm just working on getting together some statistic data for my job.

Column 1    Column 2
   1            D
   2            A
   3            D
   4            D
   5            A

What I need is to calculate an average between the numbers belonging to column 1 that correspond to cells belong to column 2 which have the value "D". I imagine the easiest way would be to just sort the whole table alphabetically around column 2, but I'm not allowed to make any changes to the table. I hope I got my point across clearly enough, thank you in advance!

1 个答案:

答案 0 :(得分:1)

Try this AVERAGEIF() Formula:

=AVERAGEIF(B:B,"D",A:A)
相关问题