Excel averageifs with or function

后端 未结 3 1975
花落未央
花落未央 2021-01-13 01:46

I am using the averageifs function, and have one column where I need to calculate the average if either of the criteria are true.

I have tried using the OR function,

3条回答
  •  猫巷女王i
    2021-01-13 02:16

    Do not think Excel has this feature, but in Google Sheets, I've been using the below to achieve similar results

    =average(filter($A:$A,($C:$C=$E$6)+($C:$C=$E$7)))
    

    giving me an average of the values in A:A where C:C matches the value in either E6 or E7

    unlike an ifs / sumifs etc., the filter uses =, not a comma, thus $C:$C=$E$6 is used, not $C:$C,$E$6

    Mathematical symbols are just entered ( so <> rather than "<>"& )

提交回复
热议问题